12021-06-19  Mike Frysinger  <vapier@gentoo.org>
2
3	* acinclude.m4: Delete most m4_include's of ../config files.
4	* configure.ac: Delete m4_include call and call AC_CONFIG_MACRO_DIR.
5	* aclocal.m4: Regenerate.
6	* configure: Regenerate.
7
82021-06-14  Mike Frysinger  <vapier@gentoo.org>
9
10	* Makefile.in (GNULIB_BUILDDIR): Rename to ...
11	(GNULIB_PARENT_DIR): ... this.  Remove "gnulib" from value.
12
132021-05-27  Simon Marchi  <simon.marchi@polymtl.ca>
14
15	* Fix some indentation mistakes throughout.
16
172021-05-17  Andrew Burgess  <andrew.burgess@embecosm.com>
18
19	* .dir-locals.el: Set sentence-end-double-space for all modes, and
20	set brace-list-open to 0 for C and C++ modes.
21
222021-05-08  Simon Marchi  <simon.marchi@polymtl.ca>
23
24	* linux-low.cc (linux_process_target::wait_for_event_filtered):
25	Adjust to status_to_str returning std::string.
26
272021-05-08  Pedro Alves  <pedro@palves.net>
28
29	* linux-low.cc:
30	(linux_process_target::supports_disable_randomization): Remove
31	reference to HAVE_PERSONALITY.
32	* config.in, configure: Regenerate.
33
342021-05-08  Pedro Alves  <pedro@palves.net>
35
36	* linux-low.cc: Don't include sys/personality.h or define
37	ADDR_NO_RANDOMIZE.
38
392021-05-06  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
40
41	* server.cc (handle_v_attach)
42	(handle_v_run)
43	(handle_v_kill): Make void.
44
452021-05-03  Tom Tromey  <tromey@adacore.com>
46
47	PR build/27807:
48	* win32-i386-low.cc (i386_get_thread_context): Call
49	Wow64GetThreadContext, not win32_Wow64GetThreadContext.
50
512021-04-30  Tom Tromey  <tromey@adacore.com>
52
53	* win32-low.cc (do_initial_child_stuff): Update.
54	(windows_nat::handle_load_dll): Rename from win32_add_one_solib.
55	Change parameter type.
56	(win32_add_dll, win32_add_all_dlls)
57	(windows_nat::handle_load_dll): Remove.
58	(get_child_debug_event): Call dll_loaded_event.
59
602021-04-30  Tom Tromey  <tromey@adacore.com>
61
62	* win32-low.cc (GETPROCADDRESS): Remove.
63	(winapi_DebugActiveProcessStop, winapi_DebugSetProcessKillOnExit)
64	(winapi_DebugBreakProcess, winapi_GenerateConsoleCtrlEvent)
65	(winapi_Wow64SetThreadContext, win32_Wow64GetThreadContext)
66	(win32_Wow64SetThreadContext): Remove.
67	(win32_set_thread_context, do_initial_child_stuff)
68	(win32_process_target::attach, win32_process_target::detach):
69	Update.
70	(winapi_EnumProcessModules, winapi_EnumProcessModulesEx)
71	(winapi_GetModuleInformation, winapi_GetModuleInformationA):
72	Remove.
73	(win32_EnumProcessModules, win32_EnumProcessModulesEx)
74	(win32_GetModuleInformation, win32_GetModuleInformationA):
75	Remove.
76	(load_psapi): Remove.
77	(win32_add_dll, win32_process_target::request_interrupt): Update.
78	(initialize_low): Call initialize_loadable.
79
802021-04-14  Tom Tromey  <tromey@adacore.com>
81
82	* win32-low.cc (windows_nat::handle_load_dll): Don't check
83	_WIN32_WCE.
84
852021-04-13  Pedro Alves  <pedro@palves.net>
86
87	* gdbreplay.c [__MINGW32CE__] (COUNTOF, errno, strerror): Remove.
88
892021-04-13  Tom Tromey  <tromey@adacore.com>
90
91	* win32-low.cc (winapi_CreateToolhelp32Snapshot)
92	(winapi_Module32First, winapi_Module32Next): Remove typedefs.
93
942021-04-13  Pedro Alves  <pedro@palves.net>
95
96	* Makefile.in (SFILES): Remove hostio-errno.cc.
97	* configure: Regenerate.
98	* configure.ac (GDBSERVER_DEPFILES): No longer add
99	$srv_hostio_err_objs.
100	* configure.srv (srv_hostio_err_objs): Delete.
101	* hostio-errno.cc: Delete.
102	* hostio.cc (hostio_error): Inline hostio_last_error_from_errno
103	here.
104	* hostio.h (hostio_last_error_from_errno): Delete.
105	* target.cc (process_stratum_target::hostio_last_error): Delete.
106	* target.h (class process_stratum_target) <hostio_last_error>:
107	Delete.
108
1092021-04-12  Simon Marchi  <simon.marchi@polymtl.ca>
110
111	* win32-low.cc: Remove all code guarded by _WIN32_WCE.
112	* win32-low.h: Likewise.
113
1142021-04-12  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
115
116	* target.h (class process_stratum_target) <pid_to_exec_file>:
117	Constify the return type.  Update the definition/references below.
118	* target.cc (process_stratum_target::pid_to_exec_file)
119	* linux-low.h (class linux_process_target) <pid_to_exec_file>
120	* linux-low.cc (linux_process_target::pid_to_exec_file)
121	* netbsd-low.h (class netbsd_process_target) <pid_to_exec_file>
122	* netbsd-low.cc (netbsd_process_target::pid_to_exec_file)
123	* server.cc (handle_qxfer_exec_file)
124
1252021-04-11  Eli Zaretskii  <eliz@gnu.org>
126
127	* win32-low.cc (win32_add_dll): New function, with body almost
128	identical to what win32_add_all_dlls did.  Accepts one argument;
129	if that is non-NULL, returns the file name of the DLL that is
130	loaded at the base address equal to that argument, or NULL if not
131	found.  If the argument is NULL, add all the DLLs loaded by the
132	inferior to the list of solibs and return NULL.
133	(win32_add_all_dlls): Now a thin wrapper around win32_add_dll.
134	(windows_nat::handle_load_dll) [!_WIN32_WCE]: If get_image_name
135	failed to glean the file name of the DLL, call win32_add_dll to
136	try harder using the lpBaseOfDll member of the load-DLL event.
137
1382021-03-30  Luis Machado  <luis.machado@linaro.org>
139
140	* server.cc (handle_general_set, handle_query): Update variable
141	to bool and fix verification logic.
142
1432021-03-24  Luis Machado  <luis.machado@linaro.org>
144
145	* Makefile.in (SFILES): Add /../gdb/nat/aarch64-mte-linux-ptrace.c.
146	* configure.srv (aarch64*-*-linux*): Add arch/aarch64-mte-linux.o and
147	nat/aarch64-mte-linux-ptrace.o.
148	* linux-aarch64-low.cc: Include nat/aarch64-mte-linux-ptrace.h.
149	(class aarch64_target) <supports_memory_tagging>
150	<fetch_memtags, store_memtags>: New method overrides.
151	(aarch64_target::supports_memory_tagging)
152	(aarch64_target::fetch_memtags)
153	(aarch64_target::store_memtags): New methods.
154
1552021-03-24  Luis Machado  <luis.machado@linaro.org>
156
157	* linux-aarch64-low.cc (aarch64_fill_mteregset): New function.
158	(aarch64_store_mteregset): New function.
159	(aarch64_regsets): Add MTE register set entry.
160	(aarch64_sve_regsets): Add MTE register set entry.
161
1622021-03-24  Luis Machado  <luis.machado@linaro.org>
163
164	* linux-aarch64-ipa.cc (get_ipa_tdesc): Update call to
165	aarch64_linux_read_description.
166	(initialize_low_tracepoint): Likewise.
167	* linux-aarch64-low.cc (aarch64_target::low_arch_setup): Take MTE flag
168	into account.
169	* linux-aarch64-tdesc.cc (tdesc_aarch64_list): Add one more dimension
170	for MTE.
171	(aarch64_linux_read_description): Add mte_p parameter and update to
172	use it.
173	* linux-aarch64-tdesc.h (aarch64_linux_read_description): Add mte_p
174	parameter.
175
1762021-03-24  Luis Machado  <luis.machado@linaro.org>
177
178	* linux-aarch64-low.cc: Include arch/aarch64-mte-linux.h.
179
1802021-03-24  Luis Machado  <luis.machado@linaro.org>
181
182	* server.cc (test_memory_tagging_functions): New function.
183	(captured_main): Register test_memory_tagging_functions.
184
1852021-03-24  Luis Machado  <luis.machado@linaro.org>
186
187	* remote-utils.cc (decode_m_packet_params): Renamed from ...
188	(decode_m_packet): ... this, which now calls decode_m_packet_params.
189	Make char * param/return const char *.
190	(decode_M_packet): Use decode_m_packet_params and make char * param
191	const char *.
192	* remote-utils.h (decode_m_packet_params): New prototype.
193	(decode_m_packet): Constify char pointers.
194	(decode_M_packet): Likewise.
195	* server.cc (create_fetch_memtags_reply)
196	(parse_store_memtags_request): New
197	functions.
198	(handle_general_set): Handle the QMemTags packet.
199	(parse_fetch_memtags_request): New function.
200	(handle_query): Handle the qMemTags packet and advertise memory
201	tagging support.
202	(captured_main): Initialize memory tagging flag.
203	* server.h (struct client_state): Initialize memory tagging flag.
204	* target.cc (process_stratum_target::supports_memory_tagging)
205	(process_stratum_target::fetch_memtags)
206	(process_stratum_target::store_memtags): New methods.
207	* target.h: Include gdbsupport/byte-vector.h.
208	(class process_stratum_target) <supports_memory_tagging>
209	<fetch_memtags, store_memtags>: New class virtual methods.
210	(target_supports_memory_tagging): Define.
211
2122021-03-22  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
213
214	* inferiors.h (struct process_info) <all_dlls, dlls_changed>: New
215	fields.
216	* dll.h (loaded_dll)
217	(unloaded_dll): Declare an overloaded version that takes a proc
218	parameter.
219	* dll.cc (loaded_dll)
220	(unloaded_dll): Implement the overloaded versions.
221	(clear_dlls): Clear all process' dll lists.
222	(all_dlls, dlls_changed): Remove the global variables.
223	* remote-utils.cc (prepare_resume_reply): Update to consider a dll
224	list per proc.
225	* server.cc (handle_qxfer_libraries): Ditto.
226	(handle_v_attach): Ditto.
227	(captured_main): Ditto.
228
2292021-02-23  Simon Marchi  <simon.marchi@polymtl.ca>
230
231	* linux-low.cc (linux_process_target::filter_event): Return
232	void.
233	* linux-low.h (class linux_process_target) <filter_event>:
234	Return void.
235
2362021-02-12  Tom Tromey  <tromey@adacore.com>
237
238	* gdbreplay.cc (remote_desc): Remove.
239	(remote_desc_in, remote_desc_out): New globals.
240	(remote_close): Update.
241	(remote_open): Handle "-".
242	(remote_open): Update.
243	(logchar): Log to stderr.
244	(expect, play): Update.
245
2462021-02-12  Tom Tromey  <tromey@adacore.com>
247
248	* gdbreplay.cc (remote_open): Constify.
249
2502021-02-05  Paul E. Murphy  <murphyp@linux.ibm.com>
251
252	* Makefile.in (UNDO_GNULIB_CFLAGS): Disable
253	gnulib free replacement too.
254	* common-defs.h [USE_WIN32API](read, write): Undefine
255	gnulib versions before defining these macros.
256
2572021-02-03  Pedro Alves  <pedro@palves.net>
258
259	* linux-low.cc (linux_process_target::complete_ongoing_step_over):
260	Discard step SIGTRAP, unless GDB wanted the thread to step.
261
2622021-02-03  Pedro Alves  <pedro@palves.net>
263
264	* server.cc (discard_queued_stop_replies): Don't ever discard the
265	notification at the head of the list.
266
2672021-01-20  Simon Marchi  <simon.marchi@polymtl.ca>
268
269	* ax.cc (bytecode_address_table): Make static.
270	* debug.cc (debug_file): Make static.
271	* linux-low.cc (stopping_threads): Make static.
272	(step_over_bkpt): Make static.
273	* linux-x86-low.cc (amd64_emit_ops, i386_emit_ops): Make static.
274	* tracepoint.cc (stop_tracing_bkpt, flush_trace_buffer_bkpt,
275	alloced_trace_state_variables, trace_buffer_ctrl,
276	tracing_start_time, tracing_stop_time, tracing_user_name,
277	tracing_notes, tracing_stop_note): Make static.
278
2792021-01-20  Tom de Vries  <tdevries@suse.de>
280
281	* linux-x86-low.cc (collect_register_i386): New function.
282	(x86_fill_gregset):  Remove memset.  Use collect_register_i386.
283
2842021-01-07  Tom de Vries  <tdevries@suse.de>
285
286	* Makefile.in (LIBIBERTY_NORMAL, LIBIBERTY_NOASAN, LIBIBERTY_PIC):
287	(LIBIBERTY_FOR_SHLIB): New var.
288	(LIBIBERTY): Set using $(LIBIBERTY_NORMAL).
289	(IPA_LIB): Use LIBIBERTY_FOR_SHLIB instead of LIBIBERTY in target rule.
290
2912021-01-04  Simon Marchi  <simon.marchi@efficios.com>
292
293	* debug.cc (debug_print_depth): New.
294
2952021-01-01  Joel Brobecker  <brobecker@adacore.com>
296
297	* server.cc (gdbserver_version): Update copyright year.
298	* gdbreplay.cc (gdbreplay_version): Likewise.
299
3002020-12-16  Luis Machado  <luis.machado@linaro.org>
301
302	* linux-aarch64-low.cc (address_significant): New function.
303	(aarch64_target::low_stopped_data_address): Handle the TBI.
304
3052020-12-11  Andrew Burgess  <andrew.burgess@embecosm.com>
306
307	* Makefile.in (IPA_LIB): Include libiberty library.
308
3092020-11-11  Andrew Burgess  <andrew.burgess@embecosm.com>
310
311	* server.cc (gdbserver_usage): Add missing option to usage text.
312	(gdbserver_show_disableable): Likewise.
313
3142020-11-02  Simon Marchi  <simon.marchi@efficios.com>
315
316	* ax.cc: Fix indentation.
317	* dll.cc: Fix indentation.
318	* inferiors.h: Fix indentation.
319	* linux-low.cc: Fix indentation.
320	* linux-nios2-low.cc: Fix indentation.
321	* linux-ppc-ipa.cc: Fix indentation.
322	* linux-ppc-low.cc: Fix indentation.
323	* linux-x86-low.cc: Fix indentation.
324	* linux-xtensa-low.cc: Fix indentation.
325	* regcache.cc: Fix indentation.
326	* server.cc: Fix indentation.
327	* tracepoint.cc: Fix indentation.
328
3292020-10-31  Simon Marchi  <simon.marchi@polymtl.ca>
330
331	* acinclude.m4: Replace AC_TRY_COMPILE with AC_COMPILE_IFELSE +
332	AC_LANG_PROGRAM.
333	* configure: Re-generate.
334
3352020-10-31  Simon Marchi  <simon.marchi@polymtl.ca>
336
337	* configure: Re-generate.
338
3392020-10-31  Simon Marchi  <simon.marchi@polymtl.ca>
340
341	* configure: Re-generate.
342
3432020-10-31  Simon Marchi  <simon.marchi@polymtl.ca>
344
345	* configure: Re-generate.
346
3472020-10-31  Simon Marchi  <simon.marchi@polymtl.ca>
348
349	* configure: Re-generate.
350
3512020-10-31  Simon Marchi  <simon.marchi@polymtl.ca>
352
353	* configure.ac: Modernize.
354	* configure: Re-generate.
355
3562020-10-31  Simon Marchi  <simon.marchi@polymtl.ca>
357
358	* configure.ac: Use AC_CANONICAL_{BUILD,HOST,TARGET} instead of
359	AC_CANONICAL_SYSTEM.
360	* configure: Re-generate.
361
3622020-10-26  Pedro Alves  <pedro@palves.net>
363
364	* netbsd-low.cc (netbsd_waitpid, netbsd_process_target::kill)
365	(netbsd_qxfer_libraries_svr4): Use gdb::handle_eintr without
366	explicit type.
367
3682020-10-25  Simon Marchi  <simon.marchi@polymtl.ca>
369
370	* acinclude.m4: Update ptrace.m4 path.
371
3722020-10-24  Simon Marchi  <simon.marchi@polymtl.ca>
373
374	* config.in: Re-generate.
375	* configure: Re-generate.
376
3772020-10-21  Simon Marchi  <simon.marchi@polymtl.ca>
378
379	* server.cc (handle_general_set): Don't use sprintf with
380	argument overlapping buffer.
381
3822020-10-20  Tom Tromey  <tromey@adacore.com>
383
384	PR gdb/26742:
385	* inferiors.cc (remove_thread): Clear current_thread before
386	freeing the thread.
387
3882020-10-13  Kamil Rytarowski  <n54@gmx.com>x
389
390	* netbsd-low.cc (netbsd_tdesc): Remove.
391	(netbsd_add_process): Likewise.
392	(netbsd_process_target::create_inferior): Update.
393
3942020-10-09  Andrew Burgess  <andrew.burgess@embecosm.com>
395
396	* linux-arc-low.cc (arc_linux_read_description): Release the
397	unique_ptr returned from arc_create_target_description.
398
3992020-10-09  Andrew Burgess  <andrew.burgess@embecosm.com>
400
401	* Makefile.in: Include Makefile.gnulib.inc.  Don't define LIBGNU
402	or INCGNU.  Make use of LIBGNU_EXTRA_LIBS when linking.
403
4042020-10-08  Andrew Burgess  <andrew.burgess@embecosm.com>
405
406	* linux-low.cc (linux_process_target::handle_extended_wait):
407	Release the unique_ptr returned from allocate_target_description.
408	* linux-riscv-low.cc (riscv_target::low_arch_setup): Likewise.
409	* linux-x86-low.cc (tdesc_amd64_linux_no_xml): Change type.
410	(tdesc_i386_linux_no_xml): Change type.
411	(x86_linux_read_description): Borrow pointer from unique_ptr
412	object.
413	(x86_target::get_ipa_tdesc_idx): Likewise.
414	(initialize_low_arch): Likewise.
415	* tdesc.cc (allocate_target_description): Update return type.
416
4172020-10-07  Tom Tromey  <tromey@adacore.com>
418
419	* server.cc (handle_search_memory): Remove dead code.
420
4212020-10-07  Tom Tromey  <tromey@adacore.com>
422
423	* server.cc (handle_search_memory_1): Remove.
424	(handle_search_memory): Use simple_search_memory.
425
4262020-10-07  Simon Marchi  <simon.marchi@efficios.com>
427
428	* Makefile.in (COMPILE): Add CXXFLAGS.
429	(INTERNAL_CFLAGS_BASE): Remove CXXFLAGS.
430	(gdbserver$(EXEEXT)): Add CXXFLAGS.
431	(gdbreplay$(EXEEXT)): Add CXXFLAGS.
432	($(IPA_LIB)): Add CXXFLAGS.
433	(IPAGENT_COMPILE): Add CXXFLAGS.
434
4352020-10-07  Anton Kolesov  <anton.kolesov@synopsys.com>
436
437	* configure.srv: Support ARC architecture.
438	* Makefile.in: Add linux-arc-low.cc and arch/arc.o.
439	* linux-arc-low.cc: New file.
440
4412020-10-07  Kamil Rytarowski  <n54@gmx.com>
442
443	* netbsd-low.cc (get_dynamic, get_r_debug, read_one_ptr)
444	(netbsd_qxfer_libraries_svr4): Remove "target" argument and update.
445	(netbsd_process_target::qxfer_libraries_svr4): Update.
446
4472020-10-07  Kamil Rytarowski  <n54@gmx.com>
448
449	* netbsd-low.cc: Fix whitespace formatting.
450	* netbsd-amd64-low.cc: Likewise.
451
4522020-10-07  Kamil Rytarowski  <n54@gmx.com>
453
454	* netbsd-low.cc (netbsd_process_target::read_memory)
455	(netbsd_process_target::write_memory): Update.
456
4572020-10-07  Kamil Rytarowski  <n54@gmx.com>
458
459	* netbsd-aarch64-low.cc: Add.
460	* Makefile.in (SFILES): Register "netbsd-aarch64-low.c".
461	* configure.srv: Add aarch64*-*-netbsd*.
462
4632020-10-06  Shahab Vahedi  <shahab@synopsys.com>
464
465	* regcache.cc (register_data): Remove unused "fetch" argument.
466
4672020-10-02  Simon Marchi  <simon.marchi@polymtl.ca>
468
469	* server.cc (handle_monitor_command): Handle "set
470	debug-event-loop".
471	(captured_main): Handle "--debug-event-loop".
472	(monitor_show_help): Mention new setting.
473	(gdbserver_usage): Mention new flag.
474
4752020-10-02  Simon Marchi  <simon.marchi@polymtl.ca>
476
477	* linux-low.cc (linux_process_target::async): Pass name to
478	add_file_handler.
479	* remote-utils.cc (handle_accept_event): Likewise.
480	(remote_open): Likewise.
481
4822020-10-01  Kamil Rytarowski  <n54@gmx.com>
483
484	* netbsd-i386-low.cc: Add.
485	* Makefile.in (SFILES): Register "netbsd-i386-low.c".
486	* configure.srv: Add i[34567]86-*-netbsd*.
487
4882020-10-01  Kamil Rytarowski  <n54@gmx.com>
489
490	* netbsd-amd64-low.cc (netbsd_x86_64_arch_setup): Remove.
491	(netbsd_target_regsets): Now const.
492	(the_low_target): Remove.
493	(class netbsd_amd64_target, the_netbsd_amd64_target)
494	(the_netbsd_target): Add.
495	* netbsd-low.cc (netbsd_process_target::post_create_inferior): Call
496	low_arch_setup ().
497	(netbsd_process_target::fetch_registers)
498	(netbsd_process_target::store_registers, initialize_low): Update.
499	(the_netbsd_target): Remove.
500	* netbsd-low.h (netbsd_target_regsets, netbsd_target_ops)
501	(the_low_target, netbsd_tdesc): Remove.
502	(netbsd_process_target::get_regs_info)
503	(netbsd_process_target::low_arch_setup): Add.
504
5052020-09-23  Hannes Domani  <ssbssa@yahoo.de>
506
507	* win32-low.cc: Remove local wow64_process variable.
508	* win32-low.h: Remove local wow64_process variable.
509
5102020-09-18  Tom Tromey  <tromey@adacore.com>
511
512	* netbsd-low.h (class netbsd_process_target) <wait>: Update.
513	* netbsd-low.cc (netbsd_waitpid, netbsd_wait)
514	(netbsd_process_target::wait): Change type of target_options.
515	* win32-low.h (class win32_process_target) <wait>: Update.
516	* win32-low.cc (win32_process_target::wait): Update.
517	* target.h (class process_stratum_target) <wait>: Update.
518	(mywait): Update.
519	* target.cc (mywait, target_wait): Change type of "options".
520	* linux-low.h (class linux_process_target) <wait, wait_1>:
521	Update.
522	* linux-low.cc (linux_process_target::wait)
523	(linux_process_target::wait_1): Update.
524
5252020-09-15  Tom Tromey  <tromey@adacore.com>
526
527	* linux-x86-low.cc (xmltarget_i386_linux_no_xml)
528	(xmltarget_amd64_linux_no_xml): Now arrays.
529
5302020-09-14  Tom Tromey  <tromey@adacore.com>
531
532	* tracepoint.cc (eval_result_names): Now const.
533	* ax.cc (gdb_agent_op_names): Now const.
534
5352020-09-10  Kamil Rytarowski  <n54@gmx.com>
536
537	* netbsd-low.cc: Add.
538	* netbsd-low.h: Likewise.
539	* netbsd-amd64-low.cc: Likewise.
540	* Makefile.in (SFILES): Register "netbsd-low.cc", "netbsd-low.h",
541	"netbsd-amd64-low.cc".
542	* configure.srv: Add x86_64-*-netbsd*.
543
5442020-08-13  Simon Marchi  <simon.marchi@polymtl.ca>
545
546	* server.cc (captured_main): Accept multiple `--selftest=`
547	options.  Pass all `--selftest=` arguments to run_tests.
548
5492020-07-30  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
550
551	* configure, config.in: Regenerate.
552
5532020-07-26  Eli Zaretskii  <eliz@gnu.org>
554
555	* configure.ac (AC_CHECK_HEADERS): Add ws2tcpip.h.
556	When checking whether socklen_t type is defined, use ws2tcpip.h if
557	it is available and sys/socket.h isn't.
558	* configure: Regenerate.
559	* config.in: Regenerate.
560
5612020-07-22  Pedro Alves  <pedro@palves.net>
562
563	* inferiors.cc (switch_to_process): New, moved here from
564	thread-db.cc, and made extern.
565	* inferiors.h (switch_to_process): Declare.
566	* server.cc: Include "gdbsupport/scoped_restore.h".
567	(handle_qxfer_threads_proper): Now returns bool.  Prepare to
568	access memory around target calls.
569	(handle_qxfer_threads): Handle errors.
570	* thread-db.cc (switch_to_process): Moved to inferiors.cc.
571
5722020-07-21  Simon Marchi  <simon.marchi@efficios.com>
573
574	* linux-low.cc (stopped_pids): Make static.
575
5762020-07-17  Andrew Burgess  <andrew.burgess@embecosm.com>
577
578	* tdesc.cc (allocate_target_description): Add header comment.
579	(target_desc_deleter::operator()): New function.
580	* tdesc.h (struct target_desc): Declare as final.
581
5822020-07-13  Simon Marchi  <simon.marchi@polymtl.ca>
583
584	* server.cc (handle_query): Use std::vector of
585	std::string for `qsupported` vector.  Use separate
586	vector for unknowns.
587	* target.h (class process_stratum_target) <process_qsupported>:
588	Change parameters to array_view of const char *.
589	(target_process_qsupported): Remove `count` parameter.
590	* target.cc (process_stratum_target::process_qsupported): Change
591	parameters to array_view of const char *.
592	* linux-x86-low.cc (class x86_target) <process_qsupported>:
593	Likewise.
594
5952020-06-29  Tom de Vries  <tdevries@suse.de>
596
597	* ax.h: Include gdbsupport/debug_agent.h.
598
5992020-06-23  Andrew Burgess  <andrew.burgess@embecosm.com>
600
601	* tdesc.cc (struct tdesc_compatible_info): New struct.
602	(tdesc_compatible_info_list): New function.
603	(tdesc_compatible_info_arch_name): New function.
604
6052020-06-22  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
606
607	Use std::list to stop pending signal instead of manually-created
608	linked list.
609	* linux-low.h: Include <list>.
610	(struct pending_signal): Move here from linux-low.cc.
611	(struct lwp_info) <pending_signals>
612	<pending_signals_to_report>: Update the type.
613	* linux-low.cc (struct pending_signals): Remove.
614	(linux_process_target::delete_lwp)
615	(linux_process_target::add_lwp)
616	(enqueue_one_deferred_signal)
617	(dequeue_one_deferred_signal)
618	(enqueue_pending_signal)
619	(linux_process_target::resume_one_lwp_throw)
620	(linux_process_target::thread_needs_step_over)
621	(linux_process_target::resume_one_thread)
622	(linux_process_target::proceed_one_lwp): Update the use of pending
623	signal list.
624
6252020-06-17  Simon Marchi  <simon.marchi@efficios.com>
626
627	* Makefile.in (%-generated.cc: ../gdb/regformats/arm/%.dat):
628	Remove.
629
6302020-06-12  Simon Marchi  <simon.marchi@efficios.com>
631
632	* Makefile.in (SFILES): Remove win32-arm-low.cc, wincecompat.cc.
633	* configure.srv: Remove mingw32ce cases.
634	* server.h, win32-low.cc: Remove __MINGW32CE__-guarded code.
635	* win32-low.h (to_back_slashes): Remove.
636	* win32-arm-low.cc, wincecompat.cc, wincecompat.h: Remove.
637
6382020-06-12  Simon Marchi  <simon.marchi@efficios.com>
639
640	* Makefile.in (SFILES): linux-tile-low.cc.
641	* configure.srv: Remove tilegx case.
642	* linux-tile-low.cc: Remove.
643
6442020-06-12  Simon Marchi  <simon.marchi@efficios.com>
645
646	* Makefile.in (SFILES): Remove linux-m32r-low.cc.
647	* configure.srv: Remove m32r case.
648	* linux-m32r-low.cc: Remove.
649
6502020-06-12  Simon Marchi  <simon.marchi@efficios.com>
651
652	* Makefile.in (SFILES): Remove linux-cris-low.c.
653	* configure.srv: Remove cris cases.
654	* linux-cris-low.cc, linux-crisv32-low.cc: Remove.
655
6562020-06-12  Simon Marchi  <simon.marchi@efficios.com>
657
658	* Makefile.in (SFILES): Remove linux-bfin-low.c.
659	* configure.srv: Remove bfin case.
660	* linux-bfin-low.cc: Remove.
661	* linux-low.cc: Remove BFIN-conditional code.
662
6632020-06-12  Simon Marchi  <simon.marchi@efficios.com>
664
665	* configure: Re-generate.
666	* configure.ac: Remove srv_qnx test.
667	* configure.srv: Remove nto case.
668	* nto-low.cc, nto-low.h, nto-x86-low.cc: Remove.
669	* remote-utils.c: Remove __QNX__-guarded code.
670
6712020-06-12  Simon Marchi  <simon.marchi@efficios.com>
672
673	* configure: Re-generate.
674	* configure.ac: Remove srv_lynxos test.
675	* configure.srv: Remove lynxos cases.
676	* lynx-i386-low.cc, lynx-low.cc, lynx-low.h, lynx-ppc-low.c:
677	Remove.
678
6792020-06-12  Simon Marchi  <simon.marchi@efficios.com>
680
681	* README: Fix a few outdated or incoherent things.
682
6832020-05-27  Hannes Domani  <ssbssa@yahoo.de>
684
685	* win32-low.cc (do_initial_child_stuff): Set open_process_used.
686	(win32_clear_inferiors): Use open_process_used.
687	(get_child_debug_event): Likewise.
688
6892020-05-25  Michael Weghorn  <m.weghorn@posteo.de>
690
691	PR gdbserver/25893
692	* linux-low.cc (linux_process_target::create_inferior),
693	lynx-low.cc (lynx_process_target::create_inferior),
694	win32-low.cc (win32_process_target::create_inferior): Use
695	construct_inferior_arguments instead of stringify_argv
696	to get string representation which properly escapes
697	special characters.
698	* server.cc (handle_v_run): Just pass empty program arg
699	as such, since any further processing is now handled via
700	construct_inferior_arguments.
701
7022020-05-25  Michael Weghorn  <m.weghorn@posteo.de>
703
704	* nto-low.cc (nto_process_target::create_inferior): Pass
705	argv to spawnp function as char **.
706
7072020-05-25  Michael Weghorn  <m.weghorn@posteo.de>
708
709	* server.cc (captured_main), (handle_v_run): No longer
710	insert extra NULL element to args vector.
711
7122020-05-23  Pedro Alves  <palves@redhat.com>
713
714	* gdb-safe-ctype.h: New.
715
7162020-05-16  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
717
718	* linux-ia64-low.cc (ia64_target::sw_breakpoint_from_kind):
719	Fix incorrect 'gdb_assert_no_reached' to 'gdb_assert_not_reached'.
720	(ia64_target::low_breakpoint_at): Ditto.
721
7222020-05-15  Hannes Domani  <ssbssa@yahoo.de>
723
724	* win32-i386-low.cc (i386_supports_z_point_type): Handle
725	Z_PACKET_HW_BP z_type.
726	(i386_insert_point): Handle raw_bkpt_type type.
727	(i386_remove_point): Likewise.
728
7292020-04-30  Hannes Domani  <ssbssa@yahoo.de>
730
731	* configure.srv <x86_64-*-mingw*, x86_64-*-cygwin*> (srv_tgtobj):
732	Add arch/i386.o.
733	* win32-arm-low.cc (arm_num_regs): New function.
734	(struct win32_target_ops): Use arm_num_regs.
735	* win32-i386-low.cc (win32_get_current_dr): Adapt for WOW64
736	processes.
737	(i386_get_thread_context): Likewise.
738	(i386_prepare_to_resume): Likewise.
739	(i386_thread_added): Likewise.
740	(i386_single_step): Likewise.
741	(i386_fetch_inferior_register): Likewise.
742	(i386_store_inferior_register): Likewise.
743	(i386_arch_setup): Likewise.
744	(i386_win32_num_regs): New function.
745	(struct win32_target_ops): Use i386_win32_num_regs.
746	* win32-low.cc (win32_get_thread_context): Adapt for WOW64
747	processes.
748	(win32_require_context): Likewise.
749	(child_add_thread): Likewise.
750	(do_initial_child_stuff): Likewise.
751	(continue_one_thread): Likewise.
752	(win32_process_target::resume): Likewise.
753	(load_psapi): Likewise.
754	(win32_add_all_dlls): Likewise.
755	(maybe_adjust_pc): Likewise.
756	(win32_process_target::qxfer_siginfo): Likewise.
757	(initialize_low): Likewise.
758	* win32-low.h (struct win32_target_ops): Change num_regs to
759	callback function.
760
7612020-04-27  Simon Marchi  <simon.marchi@efficios.com>
762
763	* configure.ac: Remove check for fs_base/gs_base in
764	user_regs_struct.
765	* configure: Re-generate.
766	* config.in: Re-generate.
767	* linux-x86-low.cc (x86_64_regmap, x86_fill_gregset,
768	x86_store_gregset): Adjust.
769
7702020-04-22  Hannes Domani  <ssbssa@yahoo.de>
771
772	* server.cc (handle_search_memory_1): Fix gdb_read_memory return value
773	comparison.
774
7752020-04-16  Tom Tromey  <tromey@adacore.com>
776
777	* win32-low.cc (windows_nat::handle_access_violation): New
778	function.
779
7802020-04-15  Simon Marchi  <simon.marchi@polymtl.ca>
781
782	* win32-low.cc (get_child_debug_event): Fix format string warning.
783
7842020-04-13  Tom Tromey  <tom@tromey.com>
785
786	* server.h (gdb_fildes_t): Remove typedef.
787	* remote-utils.c (remote_desc, list_desc): Now int.
788	(INVALID_DESCRIPTOR): Remove.
789	(gdb_connected, remote_close)
790	(check_remote_input_interrupt_request): Update.
791	* utils.h (pfildes): Don't declare.
792	* utils.c (pfildes): Remove.
793
7942020-04-13  Tom Tromey  <tom@tromey.com>
795
796	* server.h (handle_serial_event, handle_target_event): Update.
797	* server.c: Don't call initialize_event_loop.
798	(keep_processing_events): New global.
799	(handle_serial_event): Return void.  Set keep_processing_events.
800	(handle_target_event): Return void.
801	(start_event_loop): Move from event-loop.c.  Rewrite.
802	* remote-utils.c (handle_accept_event): Return void.
803	(reset_readchar): Use delete_timer.
804	(process_remaining): Return void.
805	(reschedule): Use create_timer.
806	* event-loop.h: Remove.
807	* event-loop.cc: Remove.
808	* Makefile.in (OBS): Use gdbsupport/event-loop.o, not event-loop.o.
809
8102020-04-13  Tom Tromey  <tom@tromey.com>
811
812	* server.c (invoke_async_signal_handlers)
813	(check_async_event_handlers, flush_streams, gdb_select): New
814	functions.
815
8162020-04-13  Tom Tromey  <tom@tromey.com>
817
818	* configure: Rebuild.
819	* config.in: Rebuild.
820
8212020-04-08  Tom Tromey  <tromey@adacore.com>
822
823	PR gdb/22992
824	* win32-low.c (child_continue): Call matching_pending_stop.
825	(get_child_debug_event): Call fetch_pending_stop.  Push pending
826	stop when needed.
827
8282020-04-08  Tom Tromey  <tromey@adacore.com>
829
830	* win32-low.h  (win32_process_target::stopped_by_sw_breakpoint)
831	(win32_process_target::supports_stopped_by_sw_breakpoint):
832	Declare.
833	* win32-low.c (win32_supports_z_point_type): Always handle
834	Z_PACKET_SW_BP.
835	(win32_insert_point): Call insert_memory_breakpoint when needed.
836	(win32_remove_point): Call remove_memory_breakpoint when needed.
837	(win32_process_target::stopped_by_sw_breakpoint)
838	(win32_process_target::supports_stopped_by_sw_breakpoint): New
839	methods.
840	(win32_target_ops): Update.
841	(maybe_adjust_pc): New function.
842	(win32_wait): Call maybe_adjust_pc.
843
8442020-04-08  Tom Tromey  <tromey@adacore.com>
845
846	* win32-low.h (struct win32_target_ops) <decr_pc_after_break>: New
847	field.
848	* win32-i386-low.c (the_low_target): Update.
849	* win32-arm-low.c (the_low_target): Update.
850
8512020-04-08  Tom Tromey  <tromey@adacore.com>
852
853	* win32-low.h (win32_process_target::read_pc)
854	(win32_process_target::write_pc): Declare.
855	* win32-low.c (win32_process_target::read_pc)
856	(win32_process_target::write_pc): New methods.
857	* win32-i386-low.c (i386_win32_get_pc, i386_win32_set_pc): New
858	functions.
859	(the_low_target): Update.
860	* win32-arm-low.c (arm_win32_get_pc, arm_win32_set_pc): New
861	functions.
862	(the_low_target): Update.
863
8642020-04-08  Tom Tromey  <tromey@adacore.com>
865
866	* win32-low.c (win32_kill, get_child_debug_event): Use
867	wait_for_debug_event.
868
8692020-04-08  Tom Tromey  <tromey@adacore.com>
870
871	* win32-low.c (child_continue): Call continue_last_debug_event.
872
8732020-04-08  Tom Tromey  <tromey@adacore.com>
874
875	* win32-low.c (handle_exception): Remove.
876	(windows_nat::handle_ms_vc_exception): New function.
877	(get_child_debug_event): Add "continue_status" parameter.
878	Update.
879	(win32_wait): Update.
880
8812020-04-08  Tom Tromey  <tromey@adacore.com>
882
883	* win32-low.c (windows_nat::handle_load_dll): Rename from
884	handle_load_dll.  No longer static.
885	(windows_nat::handle_unload_dll): Rename from handle_unload_dll.
886	No longer static.
887
8882020-04-08  Tom Tromey  <tromey@adacore.com>
889
890	* win32-low.c (handle_output_debug_string): Add parameter.  Change
891	return type.
892	(win32_kill, get_child_debug_event): Update.
893
8942020-04-08  Tom Tromey  <tromey@adacore.com>
895
896	* win32-low.c (current_process_handle, current_process_id)
897	(main_thread_id, last_sig, current_event, siginfo_er): Move to
898	nat/windows-nat.c.
899
9002020-04-08  Tom Tromey  <tromey@adacore.com>
901
902	* win32-low.c (get_image_name): Remove.
903	(handle_load_dll): Update.
904
9052020-04-08  Tom Tromey  <tromey@adacore.com>
906
907	* win32-low.c (windows_nat::thread_rec): Rename from thread_rec.
908	No longer static.  Change parameters.
909	(child_add_thread, child_fetch_inferior_registers)
910	(child_store_inferior_registers, win32_resume)
911	(win32_get_tib_address): Update.
912
9132020-04-08  Tom Tromey  <tromey@adacore.com>
914
915	* win32-low.h (struct win32_target_ops): Use qualified names where
916	needed.
917	* win32-i386-low.c: Add "using namespace".
918	* win32-low.c: Add "using namespace".
919	* win32-arm-low.c: Add "using namespace".
920
9212020-04-08  Tom Tromey  <tromey@adacore.com>
922
923	* win32-low.c (delete_thread_info): Don't call CloseHandle.
924
9252020-04-08  Tom Tromey  <tromey@adacore.com>
926
927	* win32-low.c (win32_require_context, suspend_one_thread): Use
928	windows_thread_info::suspend.
929	(continue_one_thread): Use windows_thread_info::resume.
930	* configure.srv (srv_tgtobj): Add windows-nat.o when needed.
931
9322020-04-08  Tom Tromey  <tromey@adacore.com>
933
934	* win32-i386-low.c (update_debug_registers)
935	(i386_prepare_to_resume, i386_thread_added): Update.
936
9372020-04-08  Tom Tromey  <tromey@adacore.com>
938
939	* win32-low.c (child_add_thread): Use new.
940	(delete_thread_info): Use delete.
941
9422020-04-08  Tom Tromey  <tromey@adacore.com>
943
944	* win32-low.h (struct windows_thread_info): Remove.
945
9462020-04-08  Tom Tromey  <tromey@adacore.com>
947
948	* win32-low.h (struct windows_thread_info): Rename from
949	win32_thread_info.  Remove typedef.
950	(struct win32_target_ops, win32_require_context): Update.
951	* win32-low.c (win32_get_thread_context)
952	(win32_set_thread_context, win32_prepare_to_resume)
953	(win32_require_context, thread_rec, child_add_thread)
954	(delete_thread_info, continue_one_thread)
955	(child_fetch_inferior_registers, child_store_inferior_registers)
956	(win32_resume, suspend_one_thread, win32_get_tib_address):
957	Update.
958	* win32-i386-low.c (update_debug_registers)
959	(win32_get_current_dr, i386_get_thread_context)
960	(i386_prepare_to_resume, i386_thread_added, i386_single_step)
961	(i386_fetch_inferior_register, i386_store_inferior_register):
962	Update.
963	* win32-arm-low.c (arm_get_thread_context)
964	(arm_fetch_inferior_register, arm_store_inferior_register):
965	Update.
966
9672020-04-02  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
968
969	* linux-low.h (struct linux_target_ops): Remove.
970	(the_low_target): Remove.
971	* linux-x86-low.cc (the_low_target): Remove.
972	* linux-aarch64-low.cc (the_low_target): Ditto.
973	* linux-arm-low.cc (the_low_target): Ditto.
974	* linux-bfin-low.cc (the_low_target): Ditto.
975	* linux-cris-low.cc (the_low_target): Ditto.
976	* linux-crisv32-low.cc (the_low_target): Ditto.
977	* linux-ia64-low.cc (the_low_target): Ditto.
978	* linux-m32r-low.cc (the_low_target): Ditto.
979	* linux-m68k-low.cc (the_low_target): Ditto.
980	* linux-mips-low.cc (the_low_target): Ditto.
981	* linux-nios2-low.cc (the_low_target): Ditto.
982	* linux-ppc-low.cc (the_low_target): Ditto.
983	* linux-riscv-low.cc (the_low_target): Ditto.
984	* linux-s390-low.cc (the_low_target): Ditto.
985	* linux-sh-low.cc (the_low_target): Ditto.
986	* linux-sparc-low.cc (the_low_target): Ditto.
987	* linux-tic6x-low.cc (the_low_target): Ditto.
988	* linux-tile-low.cc (the_low_target): Ditto.
989	* linux-xtensa-low.cc (the_low_target): Ditto.
990
9912020-04-02  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
992
993	Remove the 'get_ipa_tdesc_idx' linux target op and let a concrete
994	linux target define the op by overriding the declaration in
995	process_stratum_target.
996
997	* linux-low.h (struct linux_target_ops): Remove the op.
998	(class linux_process_target) <get_ipa_tdesc_idx>: Remove.
999	* linux-low.cc (linux_process_target::get_ipa_tdesc_idx): Remove.
1000	* linux-x86-low.cc (class x86_target) <get_ipa_tdesc_idx>: Declare.
1001	(x86_get_ipa_tdesc_idx): Turn into...
1002	(x86_target::get_ipa_tdesc_idx): ...this.
1003	(the_low_target): Remove the op field.
1004	* linux-ppc-low.cc (class ppc_target) <get_ipa_tdesc_idx>: Declare.
1005	(ppc_get_ipa_tdesc_idx): Turn into...
1006	(ppc_target::get_ipa_tdesc_idx): ...this.
1007	(the_low_target): Remove the op field.
1008	* linux-s390-low.cc (class s390_target) <get_ipa_tdesc_idx>: Declare.
1009	(s390_get_ipa_tdesc_idx): Turn into...
1010	(s390_target::get_ipa_tdesc_idx): ...this.
1011	(the_low_target): Remove the op field.
1012
10132020-04-02  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
1014
1015	Turn the 'get_syscall_trapinfo' linux target op into a method
1016	of process_stratum_target.
1017
1018	* linux-low.h (struct linux_target_ops): Remove the op.
1019	(class linux_process_target) <get_syscall_trapinfo>
1020	<gdb_catch_this_syscall>
1021	<low_supports_catch_syscall>
1022	<low_get_syscall_trapinfo>: Declare.
1023	* linux-low.cc (get_syscall_trapinfo): Turn into...
1024	(linux_process_target::get_syscall_trapinfo): ...this.
1025	(linux_process_target::low_get_syscall_trapinfo): Define.
1026	(gdb_catch_this_syscall_p): Turn into...
1027	(linux_process_target::gdb_catch_this_syscall): ...this.
1028	(linux_process_target::low_supports_catch_syscall): Define.
1029
1030	Update the callers below.
1031
1032	(linux_process_target::wait_1)
1033	(linux_process_target::supports_catch_syscall)
1034
1035	* linux-x86-low.cc (class x86_target) <low_supports_catch_syscall>
1036	<low_get_syscall_trapinfo>: Declare.
1037	(x86_target::low_supports_catch_syscall): Define.
1038	(x86_get_syscall_trapinfo): Turn into...
1039	(x86_target::low_get_syscall_trapinfo): ...this.
1040	(the_low_target): Remove the op field.
1041	* linux-aarch64-low.cc (class aarch64_target)
1042	<low_supports_catch_syscall>
1043	<low_get_syscall_trapinfo>: Declare.
1044	(aarch64_target::low_supports_catch_syscall): Define.
1045	(aarch64_get_syscall_trapinfo): Turn into...
1046	(aarch64_target::low_get_syscall_trapinfo): ...this.
1047	(the_low_target): Remove the op field.
1048	* linux-arm-low.cc (class arm_target) <low_supports_catch_syscall>
1049	<low_get_syscall_trapinfo>: Declare.
1050	(arm_target::low_supports_catch_syscall): Define.
1051	(arm_get_syscall_trapinfo): Turn into...
1052	(arm_target::low_get_syscall_trapinfo): ...this.
1053	(the_low_target): Remove the op field.
1054	* linux-ppc-low.cc (the_low_target): Remove the op field.
1055	* linux-s390-low.cc (the_low_target): Remove the op field.
1056
10572020-04-02  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
1058
1059	Remove the 'supports_hardware_single_step' linux target op and
1060	override the process_stratum_target's op definition in
1061	linux_process_target to return true.
1062
1063	* linux-low.h (struct linux_target_ops): Remove the op.
1064	(class linux_process_target) <finish_step_over>
1065	<maybe_hw_step>: Declare.
1066	* linux-low.cc (can_hardware_single_step): Remove.
1067	(maybe_hw_step): Turn into...
1068	(linux_process_target::maybe_hw_step): ...this.
1069	(finish_step_over): Turn into...
1070	(linux_process_target::finish_step_over): ...this.
1071	(linux_process_target::supports_hardware_single_step): Update
1072	to return true.
1073
1074	Update the callers below.
1075
1076	(linux_process_target::single_step)
1077	(linux_process_target::resume_one_lwp_throw)
1078
1079	* linux-arm-low.cc (class arm_target)
1080	<supports_hardware_single_step>: Declare.
1081	(arm_supports_hardware_single_step): Turn into...
1082	(arm_target::supports_hardware_single_step): ...this.
1083	(the_low_target): Remove the op field.
1084	* linux-x86-low.cc (x86_supports_hardware_single_step): Remove.
1085	(the_low_target): Remove the op field.
1086	* linux-aarch64-low.cc (aarch64_supports_hardware_single_step):
1087	Remove.
1088	(the_low_target): Remove the op field.
1089	* linux-bfin-low.cc (bfin_supports_hardware_single_step): Remove.
1090	(the_low_target): Remove the op field.
1091	* linux-crisv32-low.cc (cris_supports_hardware_single_step): Remove.
1092	(the_low_target): Remove the op field.
1093	* linux-m32r-low.cc (m32r_supports_hardware_single_step): Remove.
1094	(the_low_target): Remove the op field.
1095	* linux-m68k-low.cc (m68k_supports_hardware_single_step): Remove.
1096	(the_low_target): Remove the op field.
1097	* linux-ppc-low.cc (ppc_supports_hardware_single_step): Remove.
1098	(the_low_target): Remove the op field.
1099	* linux-s390-low.cc (s390_supports_hardware_single_step): Remove.
1100	(the_low_target): Remove the op field.
1101	* linux-sh-low.cc (sh_supports_hardware_single_step): Remove.
1102	(the_low_target): Remove the op field.
1103	* linux-tic6x-low.cc (tic6x_supports_hardware_single_step): Remove.
1104	(the_low_target): Remove the op field.
1105	* linux-tile-low.cc (tile_supports_hardware_single_step): Remove.
1106	(the_low_target): Remove the op field.
1107	* linux-xtensa-low.cc (xtensa_supports_hardware_single_step):
1108	Remove.
1109	(the_low_target): Remove the op field.
1110
11112020-04-02  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
1112
1113	Turn the 'supports_range_stepping' linux target op into a method
1114	of linux_process_target.
1115
1116	* linux-low.h (struct linux_target_ops): Remove the op.
1117	(class linux_process_target) <low_supports_range_stepping>: Declare.
1118	* linux-low.cc (linux_process_target::low_supports_range_stepping):
1119	Define.
1120	(linux_process_target::supports_range_stepping): Update the call
1121	site.
1122	* linux-x86-low.cc (class x86_target)
1123	<low_supports_range_stepping>: Declare.
1124	(x86_supports_range_stepping): Turn into...
1125	(x86_target::low_supports_range_stepping): ...this.
1126	(the_low_target): Remove the op field.
1127	* linux-aarch64-low.cc (class aarch64_target)
1128	<low_supports_range_stepping>: Declare.
1129	(aarch64_supports_range_stepping): Turn into...
1130	(aarch64_target::low_supports_range_stepping): ...this.
1131	(the_low_target): Remove the op field.
1132	* linux-arm-low.cc (the_low_target): Remove the op field.
1133	* linux-bfin-low.cc (the_low_target): Ditto.
1134	* linux-crisv32-low.cc (the_low_target): Ditto.
1135	* linux-m32r-low.cc (the_low_target): Ditto.
1136	* linux-m68k-low.cc (the_low_target): Ditto.
1137	* linux-ppc-low.cc (the_low_target): Ditto.
1138	* linux-s390-low.cc (the_low_target): Ditto.
1139	* linux-sh-low.cc (the_low_target): Ditto.
1140	* linux-tic6x-low.cc (the_low_target): Ditto.
1141	* linux-tile-low.cc (the_low_target): Ditto.
1142	* linux-xtensa-low.cc (the_low_target): Ditto.
1143
11442020-04-02  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
1145
1146	Remove the 'emit_ops' linux target ops and let the concrete
1147	linux target define the op by overriding the declaration of
1148	process_stratum_target.
1149
1150	* linux-low.h (struct linux_target_ops): Remove the op.
1151	(class linux_process_target) <emit_ops>: Remove.
1152	* linux-low.cc (linux_process_target::emit_ops): Remove.
1153	* linux-x86-low.cc (class x86_target) <emit_ops>: Declare.
1154	(x86_emit_ops): Turn into...
1155	(x86_target::emit_ops): ...this.
1156	(the_low_target): Remove the op field.
1157	* linux-aarch64-low.cc (class aarch64_target) <emit_ops>: Declare.
1158	(aarch64_emit_ops): Turn into...
1159	(aarch64_target::emit_ops): ...this.
1160	(the_low_target): Remove the op field.
1161	* linux-ppc-low.cc (class ppc_target) <emit_ops>: Declare.
1162	(ppc_emit_ops): Turn into...
1163	(ppc_target::emit_ops): ...this.
1164	(the_low_target): Remove the op field.
1165	* linux-s390-low.cc (class s390_target) <emit_ops>: Declare.
1166	(s390_emit_ops): Turn into...
1167	(s390_target::emit_ops): ...this.
1168	(the_low_target): Remove the op field.
1169	* linux-arm-low.cc (the_low_target): Remove the op field.
1170	* linux-bfin-low.cc (the_low_target): Ditto.
1171	* linux-crisv32-low.cc (the_low_target): Ditto.
1172	* linux-m32r-low.cc (the_low_target): Ditto.
1173	* linux-m68k-low.cc (the_low_target): Ditto.
1174	* linux-sh-low.cc (the_low_target): Ditto.
1175	* linux-tic6x-low.cc (the_low_target): Ditto.
1176	* linux-tile-low.cc (the_low_target): Ditto.
1177	* linux-xtensa-low.cc (the_low_target): Ditto.
1178
11792020-04-02  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
1180
1181	Remove the 'install_fast_tracepoint_jump_pad' and
1182	'get_min_fast_tracepoint_insn_len' linux target ops to let the
1183	concrete linux target define the ops by overriding the declarations
1184	of process_stratum_target.
1185
1186	* linux-low.h (struct linux_target_ops): Remove the ops.
1187	(class linux_process_target) <supports_fast_tracepoints>
1188	<install_fast_tracepoint_jump_pad>
1189	<get_min_fast_tracepoint_insn_len>: Remove.
1190	* linux-low.cc (linux_process_target::supports_fast_tracepoints)
1191	(linux_process_target::install_fast_tracepoint_jump_pad)
1192	(linux_process_target::get_min_fast_tracepoint_insn_len): Remove.
1193	* linux-x86-low.cc (class x86_target) <supports_fast_tracepoints>
1194	<install_fast_tracepoint_jump_pad>
1195	<get_min_fast_tracepoint_insn_len>: Declare.
1196	(x86_target::supports_fast_tracepoints): Define.
1197	(x86_install_fast_tracepoint_jump_pad): Turn into...
1198	(x86_target::install_fast_tracepoint_jump_pad): ...this.
1199	(x86_get_min_fast_tracepoint_insn_len): Turn into...
1200	(x86_target::get_min_fast_tracepoint_insn_len): ...this.
1201	(the_low_target): Remove the op fields.
1202	* linux-aarch64-low.cc (class aarch64_target)
1203	<supports_fast_tracepoints>
1204	<install_fast_tracepoint_jump_pad>
1205	<get_min_fast_tracepoint_insn_len>: Declare.
1206	(aarch64_target::supports_fast_tracepoints): Define.
1207	(aarch64_install_fast_tracepoint_jump_pad): Turn into...
1208	(aarch64_target::install_fast_tracepoint_jump_pad): ...this.
1209	(aarch64_get_min_fast_tracepoint_insn_len): Turn into...
1210	(aarch64_target::get_min_fast_tracepoint_insn_len): ...this.
1211	(the_low_target): Remove the op fields.
1212	* linux-ppc-low.cc (class ppc_target) <supports_fast_tracepoints>
1213	<install_fast_tracepoint_jump_pad>
1214	<get_min_fast_tracepoint_insn_len>: Declare.
1215	(ppc_target::supports_fast_tracepoints): Define.
1216	(ppc_install_fast_tracepoint_jump_pad): Turn into...
1217	(ppc_target::install_fast_tracepoint_jump_pad): ...this.
1218	(ppc_get_min_fast_tracepoint_insn_len): Turn into...
1219	(ppc_target::get_min_fast_tracepoint_insn_len): ...this.
1220	(the_low_target): Remove the op fields.
1221	* linux-s390-low.cc (class s390_target) <supports_fast_tracepoints>
1222	<install_fast_tracepoint_jump_pad>
1223	<get_min_fast_tracepoint_insn_len>: Declare.
1224	(s390_target::supports_fast_tracepoints): Define.
1225	(s390_install_fast_tracepoint_jump_pad): Turn into...
1226	(s390_target::install_fast_tracepoint_jump_pad): ...this.
1227	(s390_get_min_fast_tracepoint_insn_len): Turn into...
1228	(s390_target::get_min_fast_tracepoint_insn_len): ...this.
1229	(the_low_target): Remove the op fields.
1230	* linux-arm-low.cc (the_low_target): Remove the op fields.
1231	* linux-bfin-low.cc (the_low_target): Ditto.
1232	* linux-crisv32-low.cc (the_low_target): Ditto.
1233	* linux-m32r-low.cc (the_low_target): Ditto.
1234	* linux-m68k-low.cc (the_low_target): Ditto.
1235	* linux-sh-low.cc (the_low_target): Ditto.
1236	* linux-tic6x-low.cc (the_low_target): Ditto.
1237	* linux-tile-low.cc (the_low_target): Ditto.
1238	* linux-xtensa-low.cc (the_low_target): Ditto.
1239
12402020-04-02  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
1241
1242	Turn the 'get_thread_area' linux target op into a method of
1243	process_stratum_target.
1244
1245	* linux-low.h (struct linux_target_ops): Remove the op.
1246	(class linux_process_target) <stuck_in_jump_pad>
1247	<linux_fast_tracepoint_collecting>
1248	<low_get_thread_area>: Declare.
1249	* linux-low.cc (supports_fast_tracepoints): Remove.
1250	(linux_fast_tracepoint_collecting): Turn into...
1251	(linux_process_target::linux_fast_tracepoint_collecting): ...this.
1252	(linux_process_target::low_get_thread_area): Define.
1253	(stuck_in_jump_pad_callback): Turn into...
1254	(linux_process_target::stuck_in_jump_pad): ...this.
1255
1256	Update the caller below.
1257
1258	(linux_process_target::stabilize_threads)
1259
1260	* linux-x86-low.cc (class x86_target) <low_get_thread_area>:
1261	Declare.
1262	(x86_get_thread_area): Turn into...
1263	(x86_target::low_get_thread_area): ...this.
1264	(the_low_target): Remove the op field.
1265	* linux-aarch64-low.cc (class aarch64_target) <low_get_thread_area>:
1266	Declare.
1267	(aarch64_get_thread_area): Turn into...
1268	(aarch64_target::low_get_thread_area): ...this.
1269	(the_low_target): Remove the op field.
1270	* linux-ppc-low.cc (class ppc_target) <low_get_thread_area>:
1271	Declare.
1272	(ppc_get_thread_area): Turn into...
1273	(ppc_target::low_get_thread_area): ...this.
1274	(the_low_target): Remove the op field.
1275	* linux-s390-low.cc (class s390_target) <low_get_thread_area>:
1276	Declare.
1277	(s390_get_thread_area): Turn into...
1278	(s390_target::low_get_thread_area): ...this.
1279	(the_low_target): Remove the op field.
1280	* linux-arm-low.cc (the_low_target): Remove the op field.
1281	* linux-bfin-low.cc (the_low_target): Ditto.
1282	* linux-crisv32-low.cc (the_low_target): Ditto.
1283	* linux-m32r-low.cc (the_low_target): Ditto.
1284	* linux-m68k-low.cc (the_low_target): Ditto.
1285	* linux-sh-low.cc (the_low_target): Ditto.
1286	* linux-tic6x-low.cc (the_low_target): Ditto.
1287	* linux-tile-low.cc (the_low_target): Ditto.
1288	* linux-xtensa-low.cc (the_low_target): Ditto.
1289
12902020-04-02  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
1291
1292	Remote the 'supports_tracepoints' linux target op and let the
1293	concrete linux target define it by overriding the op declared in
1294	process_stratum_target.
1295
1296	* linux-low.h (struct linux_target_ops): Remove the op.
1297	(class linux_process_target) <supports_tracepoints>: Remove.
1298	* linux-low.cc (linux_process_target::supports_tracepoints): Remove.
1299	* linux-x86-low.cc (class x86_target) <supports_tracepoints>:
1300	Declare.
1301	(x86_supports_tracepoints): Turn into...
1302	(x86_target::supports_tracepoints): ...this.
1303	(the_low_target): Remove the op field.
1304	* linux-aarch64-low.cc (class aarch64_target)
1305	<supports_tracepoints>: Declare.
1306	(aarch64_supports_tracepoints): Turn into...
1307	(aarch64_target::supports_tracepoints): ...this.
1308	(the_low_target): Remove the op field.
1309	* linux-ppc-low.cc (class ppc_target) <supports_tracepoints>:
1310	Declare.
1311	(ppc_supports_tracepoints): Turn into...
1312	(ppc_target::supports_tracepoints): ...this.
1313	(the_low_target): Remove the op field.
1314	* linux-s390-low.cc (class s390_target) <supports_tracepoints>:
1315	Declare.
1316	(s390_supports_tracepoints): Turn into...
1317	(s390_target::supports_tracepoints): ...this.
1318	(the_low_target): Remove the op field.
1319	* linux-arm-low.cc (the_low_target): Remove the op field.
1320	* linux-bfin-low.cc (the_low_target): Ditto.
1321	* linux-crisv32-low.cc (the_low_target): Ditto.
1322	* linux-m32r-low.cc (the_low_target): Ditto.
1323	* linux-m68k-low.cc (the_low_target): Ditto.
1324	* linux-sh-low.cc (the_low_target): Ditto.
1325	* linux-tic6x-low.cc (the_low_target): Ditto.
1326	* linux-tile-low.cc (the_low_target): Ditto.
1327	* linux-xtensa-low.cc (the_low_target): Ditto.
1328
13292020-04-02  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
1330
1331	Remove the 'process_qsupported' linux target op and let a concrete
1332	linux target define the op by overriding the op declaration in
1333	process_stratum_target.
1334
1335	* linux-low.h (struct linux_target_ops): Remove the op.
1336	(class linux_process_target) <process_qsupported>: Remove.
1337	* linux-low.cc (linux_process_target::process_qsupported): Remove.
1338	* linux-x86-low.cc (class x86_target) <process_qsupported>: Declare.
1339	(x86_linux_process_qsupported): Turn into...
1340	(x86_target::process_qsupported): ...this.
1341	(the_low_target): Remove the op field.
1342	* linux-aarch64-low.cc (the_low_target): Remove the op
1343	field.
1344	* linux-arm-low.cc (the_low_target): Ditto.
1345	* linux-bfin-low.cc (the_low_target): Ditto.
1346	* linux-crisv32-low.cc (the_low_target): Ditto.
1347	* linux-m32r-low.cc (the_low_target): Ditto.
1348	* linux-m68k-low.cc (the_low_target): Ditto.
1349	* linux-ppc-low.cc (the_low_target): Ditto.
1350	* linux-s390-low.cc (the_low_target): Ditto.
1351	* linux-sh-low.cc (the_low_target): Ditto.
1352	* linux-tic6x-low.cc (the_low_target): Ditto.
1353	* linux-tile-low.cc (the_low_target): Ditto.
1354	* linux-xtensa-low.cc (the_low_target): Ditto.
1355
13562020-04-02  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
1357
1358	Turn the 'prepare_to_resume' linux target op into a method of
1359	linux_process_target.
1360
1361	* linux-low.h (struct linux_target_ops): Remove the op.
1362	(class linux_process_target) <low_prepare_to_resume>: Declare.
1363	* linux-low.cc (linux_process_target::low_prepare_to_resume):
1364	Define.
1365
1366	Update the callers below:
1367
1368	(linux_process_target::resume_one_lwp_throw)
1369	(linux_process_target::low_prepare_to_resume)
1370
1371	* linux-x86-low.cc (class x86_target) <low_prepare_to_resume>:
1372	Declare.
1373	(x86_target::low_prepare_to_resume): Define.
1374	(the_low_target): Remove the op field.
1375	* linux-aarch64-low.cc (class aarch64_target)
1376	<low_prepare_to_resume>: Declare.
1377	(aarch64_target::low_prepare_to_resume): Define.
1378	(the_low_target): Remove the op field.
1379	* linux-arm-low.cc (class arm_target) <low_prepare_to_resume>:
1380	Declare.
1381	(arm_prepare_to_resume): Turn into...
1382	(arm_target::low_prepare_to_resume): ...this.
1383	(the_low_target): Remove the op field.
1384	* linux-mips-low.cc (class mips_target) <low_prepare_to_resume>:
1385	Declare.
1386	(mips_linux_prepare_to_resume): Turn into...
1387	(mips_target::low_prepare_to_resume): ...this.
1388	(the_low_target): Remove the op field.
1389	* linux-bfin-low.cc (the_low_target): Remove the op field.
1390	* linux-crisv32-low.cc (the_low_target): Ditto.
1391	* linux-m32r-low.cc (the_low_target): Ditto.
1392	* linux-m68k-low.cc (the_low_target): Ditto.
1393	* linux-ppc-low.cc (the_low_target): Ditto.
1394	* linux-s390-low.cc (the_low_target): Ditto.
1395	* linux-sh-low.cc (the_low_target): Ditto.
1396	* linux-tic6x-low.cc (the_low_target): Ditto.
1397	* linux-tile-low.cc (the_low_target): Ditto.
1398	* linux-xtensa-low.cc (the_low_target): Ditto.
1399
14002020-04-02  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
1401
1402	Turn the 'new_process', 'delete_process', 'new_thread',
1403	'delete_thread', and 'new_fork' linux target ops into methods
1404	of linux_process_target.
1405
1406	* linux-low.h (struct linux_target_ops): Remove the ops.
1407	(class linux_process_target) <add_linux_process>
1408	<add_lwp>
1409	<delete_lwp>
1410	<attach_lwp>
1411	<detach_one_lwp>
1412	<check_zombie_leaders>
1413	<filter_exit_event>
1414	<low_new_process>
1415	<low_delete_process>
1416	<low_new_thread>
1417	<low_delete_thread>
1418	<low_new_fork>: Declare.
1419	* linux-low.cc (delete_lwp): Turn into...
1420	(linux_process_target::delete_lwp): ...this.
1421	(linux_process_target::low_delete_thread): Define.
1422	(linux_add_process): Turn into...
1423	(linux_process_target::add_linux_process): ...this.
1424	(linux_process_target::low_new_process): Define.
1425	(linux_process_target::low_delete_process): Define.
1426	(linux_process_target::low_new_fork): Define.
1427	(add_lwp): Turn into...
1428	(linux_process_target::add_lwp): ...this.
1429	(linux_process_target::low_new_thread): Define.
1430	(linux_attach_lwp): Turn into...
1431	(linux_process_target::attach_lwp): ...this.
1432	(linux_detach_one_lwp): Turn into...
1433	(linux_process_target::detach_one_lwp): ...this.
1434	(linux_detach_lwp_callback): Remove and inline...
1435	(linux_process_target::detach): ...here.
1436	(check_zombie_leaders): Turn into...
1437	(linux_process_target::check_zombie_leaders): ...this.
1438	(filter_exit_event): Turn into...
1439	(linux_process_target::filter_exit_event): ...this.
1440
1441	Update the callers below.
1442
1443	(linux_process_target::handle_extended_wait)
1444	(linux_process_target::create_inferior)
1445	(attach_proc_task_lwp_callback)
1446	(linux_process_target::attach)
1447	(linux_process_target::detach)
1448	(linux_process_target::mourn)
1449	* thread-db.cc (attach_thread)
1450
1451	* linux-x86-low.cc (class x86_target) <low_new_process>
1452	<low_delete_process>
1453	<low_new_thread>
1454	<low_delete_thread>
1455	<low_new_fork>: Declare.
1456	(x86_linux_new_process): Turn into...
1457	(x86_target::low_new_process): ...this.
1458	(x86_linux_delete_process): Turn into...
1459	(x86_target::low_delete_process): ...this.
1460	(x86_target::low_new_thread): Define.
1461	(x86_target::low_delete_thread): Define.
1462	(x86_linux_new_fork): Turn into...
1463	(x86_target::low_new_fork): ...this.
1464	(the_low_target): Remove the op fields.
1465	* linux-aarch64-low.cc (class aarch64_target) <low_new_process>
1466	<low_delete_process>
1467	<low_new_thread>
1468	<low_delete_thread>
1469	<low_new_fork>: Declare.
1470	(aarch64_linux_new_process): Turn into...
1471	(aarch64_target::low_new_process): ...this.
1472	(aarch64_linux_delete_process): Turn into...
1473	(aarch64_target::low_delete_process): ...this.
1474	(aarch64_target::low_new_thread): Define.
1475	(aarch64_target::low_delete_thread): Define.
1476	(aarch64_linux_new_fork): Turn into...
1477	(aarch64_target::low_new_fork): ...this.
1478	(the_low_target): Remove the op fields.
1479	* linux-arm-low.cc (class arm_target) <low_new_process>
1480	<low_delete_process>
1481	<low_new_thread>
1482	<low_delete_thread>
1483	<low_new_fork>: Declare.
1484	(arm_new_process): Turn into...
1485	(arm_target::low_new_process): ...this.
1486	(arm_delete_process): Turn into...
1487	(arm_target::low_delete_process): ...this.
1488	(arm_new_thread): Turn into...
1489	(arm_target::low_new_thread): ...this.
1490	(arm_delete_thread): Turn into...
1491	(arm_target::low_delete_thread): ...this.
1492	(arm_new_fork): Turn into...
1493	(arm_target::low_new_fork): ...this.
1494	(the_low_target): Remove the op fields.
1495	* linux-mips-low.cc (class mips_target) <low_new_process>
1496	<low_delete_process>
1497	<low_new_thread>
1498	<low_delete_thread>
1499	<low_new_fork>: Declare.
1500	(mips_linux_new_process): Turn into...
1501	(mips_target::low_new_process): ...this.
1502	(mips_linux_delete_process): Turn into...
1503	(mips_target::low_delete_process): ...this.
1504	(mips_linux_new_thread): Turn into...
1505	(mips_target::low_new_thread): ...this.
1506	(mips_linux_delete_thread): Turn into...
1507	(mips_target::low_delete_thread): ...this.
1508	(mips_linux_new_fork): Turn into...
1509	(mips_target::low_new_fork): ...this.
1510	(the_low_target): Remove the op fields.
1511	* linux-bfin-low.cc (the_low_target): Remove the op fields.
1512	* linux-crisv32-low.cc (the_low_target): Ditto.
1513	* linux-m32r-low.cc (the_low_target): Ditto.
1514	* linux-m68k-low.cc (the_low_target): Ditto.
1515	* linux-ppc-low.cc (the_low_target): Ditto.
1516	* linux-s390-low.cc (the_low_target): Ditto.
1517	* linux-sh-low.cc (the_low_target): Ditto.
1518	* linux-tic6x-low.cc (the_low_target): Ditto.
1519	* linux-tile-low.cc (the_low_target): Ditto.
1520	* linux-xtensa-low.cc (the_low_target): Ditto.
1521
15222020-04-02  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
1523
1524	Turn the 'siginfo_fixup' linux target op into a method of
1525	linux_process_target.
1526
1527	* linux-low.h (struct linux_target_ops): Remove the op.
1528	(class linux_process_target) <siginfo_fixup>
1529	<low_siginfo_fixup>: Declare.
1530	* linux-low.cc (siginfo_fixup): Turn into...
1531	(linux_process_target::siginfo_fixup): ...this.
1532	(linux_process_target::low_siginfo_fixup): Define.
1533	* linux-x86-low.cc (class x86_target) <low_siginfo_fixup>: Declare.
1534	(x86_siginfo_fixup): Turn into...
1535	(x86_target::low_siginfo_fixup): ...this.
1536	(the_low_target): Remove the op field.
1537	* linux-aarch64-low.cc (class aarch64_target):
1538	<low_siginfo_fixup>: Declare.
1539	(aarch64_linux_siginfo_fixup): Turn into...
1540	(aarch64_target::low_siginfo_fixup): ...this.
1541	(the_low_target): Remove the op field.
1542	* linux-arm-low.cc (the_low_target): Remove the op field.
1543	* linux-bfin-low.cc (the_low_target): Ditto.
1544	* linux-crisv32-low.cc (the_low_target): Ditto.
1545	* linux-m32r-low.cc (the_low_target): Ditto.
1546	* linux-m68k-low.cc (the_low_target): Ditto.
1547	* linux-mips-low.cc (the_low_target): Ditto.
1548	* linux-ppc-low.cc (the_low_target): Ditto.
1549	* linux-s390-low.cc (the_low_target): Ditto.
1550	* linux-sh-low.cc (the_low_target): Ditto.
1551	* linux-tic6x-low.cc (the_low_target): Ditto.
1552	* linux-tile-low.cc (the_low_target): Ditto.
1553	* linux-xtensa-low.cc (the_low_target): Ditto.
1554
15552020-04-02  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
1556
1557	Turn the 'collect_ptrace_register' and 'supply_ptrace_register'
1558	linux target ops into methods of linux_process_target.
1559
1560	* linux-low.h (struct linux_target_ops): Remove the ops.
1561	(class linux_process_target) <low_collect_ptrace_register>
1562	<low_store_ptrace_register>: Declare.
1563	* linux-low.cc (linux_process_target::low_collect_ptrace_register)
1564	(linux_process_target::low_supply_ptrace_register): Define.
1565
1566	Update the callers below.
1567
1568	(linux_process_target::fetch_register)
1569	(linux_process_target::store_register)
1570
1571	* linux-x86-low.cc (the_low_target): Remove the op fields.
1572	* linux-aarch64-low.cc (the_low_target): Ditto.
1573	* linux-arm-low.cc (the_low_target): Ditto.
1574	* linux-bfin-low.cc (the_low_target): Ditto.
1575	* linux-crisv32-low.cc (the_low_target): Ditto.
1576	* linux-m32r-low.cc (the_low_target): Ditto.
1577	* linux-m68k-low.cc (the_low_target): Ditto.
1578	* linux-sh-low.cc (the_low_target): Ditto.
1579	* linux-sparc-low.cc (the_low_target): Ditto.
1580	* linux-tic6x-low.cc (the_low_target): Ditto.
1581	* linux-tile-low.cc (the_low_target): Ditto.
1582	* linux-xtensa-low.cc (the_low_target): Ditto.
1583	* linux-mips-low.cc (class mips_target)
1584	<low_collect_ptrace_register>
1585	<low_supply_ptrace_register>: Declare.
1586	(mips_collect_ptrace_register): Turn into ...
1587	(mips_target::low_collect_ptrace_register): ...this.
1588	(mips_supply_ptrace_register): Turn into...
1589	(mips_target::low_supply_ptrace_register): ...this.
1590	(the_low_target): Remove the op fields.
1591	* linux-ppc-low.cc (class ppc_target)
1592	<low_collect_ptrace_register>
1593	<low_supply_ptrace_register>: Declare.
1594	(ppc_collect_ptrace_register): Turn into ...
1595	(ppc_target::low_collect_ptrace_register): ...this.
1596	(ppc_supply_ptrace_register): Turn into ...
1597	(ppc_target::low_supply_ptrace_register): ...this.
1598	(ppc_fill_gregset): Update for the calls to
1599	low_collect_ptrace_register.
1600	(the_low_target): Remove the op fields.
1601	* linux-s390-low.cc (class s390_target)
1602	<low_collect_ptrace_register>
1603	<low_supply_ptrace_register>: Declare.
1604	(s390_collect_ptrace_register): Turn into ...
1605	(s390_target::low_collect_ptrace_register): ...this.
1606	(s390_supply_ptrace_register): Turn into ...
1607	(s390_target::low_supply_ptrace_register): ...this.
1608	(s390_fill_gregset): Update for the calls to
1609	low_collect_ptrace_register.
1610	(the_low_target): Remove the op fields.
1611
16122020-04-02  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
1613
1614	Turn the 'stopped_by_watchpoint' and 'stopped_data_address' linux
1615	target ops into methods of linux_process_target.
1616
1617	* linux-low.h (struct linux_target_ops): Remove the ops.
1618	(class linux_process_target) <check_stopped_by_watchpoint>
1619	<low_stopped_by_watchpoint>
1620	<low_stopped_data_address>: Declare.
1621	* linux-low.cc (check_stopped_by_watchpoint): Turn into...
1622	(linux_process_target::check_stopped_by_watchpoint): ...this.
1623	(linux_process_target::low_stopped_by_watchpoint): Define.
1624	(linux_process_target::low_stopped_data_address): Define.
1625	* linux-x86-low.cc (class x86_target) <low_stopped_by_watchpoint>
1626	<low_stopped_data_address>: Declare.
1627	(x86_stopped_by_watchpoint): Turn into...
1628	(x86_target::low_stopped_by_watchpoint): ...this.
1629	(x86_stopped_data_address): Turn into...
1630	(x86_target::low_stopped_data_address): ...this.
1631	(the_low_target): Remove the op fields.
1632	* linux-aarch64-low.cc (class aarch64_target)
1633	<low_stopped_by_watchpoint>
1634	<low_stopped_data_address>: Declare.
1635	(aarch64_stopped_by_watchpoint): Turn into...
1636	(aarch64_target::low_stopped_by_watchpoint): ...this.
1637	(aarch64_stopped_data_address): Turn into...
1638	(aarch64_target::low_stopped_data_address): ...this.
1639	(the_low_target): Remove the op fields.
1640	* linux-arm-low.cc (class arm_target) <low_stopped_by_watchpoint>
1641	<low_stopped_data_address>: Declare.
1642	(arm_stopped_by_watchpoint): Turn into...
1643	(arm_target::low_stopped_by_watchpoint): ...this.
1644	(arm_stopped_data_address): Turn into...
1645	(arm_target::low_stopped_data_address): ...this.
1646	(the_low_target): Remove the op fields.
1647	* linux-crisv32-low.cc (class crisv32_target)
1648	<low_stopped_by_watchpoint>
1649	<low_stopped_data_address>: Declare.
1650	(cris_stopped_by_watchpoint): Turn into...
1651	(crisv32_target::low_stopped_by_watchpoint): ...this.
1652	(cris_stopped_data_address): Turn into...
1653	(crisv32_target::low_stopped_data_address): ...this.
1654	(the_low_target): Remove the op fields.
1655	* linux-mips-low.cc (class mips_target) <low_stopped_by_watchpoint>
1656	<low_stopped_data_address>: Declare.
1657	(mips_stopped_by_watchpoint): Turn into...
1658	(mips_target::low_stopped_by_watchpoint): ...this.
1659	(mips_stopped_data_address): Turn into...
1660	(mips_target::low_stopped_data_address): ...this.
1661	(the_low_target): Remove the op fields.
1662	* linux-bfin-low.cc (the_low_target): Remove the op fields.
1663	* linux-m32r-low.cc (the_low_target): Ditto.
1664	* linux-m68k-low.cc (the_low_target): Ditto.
1665	* linux-ppc-low.cc (the_low_target): Ditto.
1666	* linux-s390-low.cc (the_low_target): Ditto.
1667	* linux-sh-low.cc (the_low_target): Ditto.
1668	* linux-sparc-low.cc (the_low_target): Ditto.
1669	* linux-tic6x-low.cc (the_low_target): Ditto.
1670	* linux-tile-low.cc (the_low_target): Ditto.
1671	* linux-xtensa-low.cc (the_low_target): Ditto.
1672
16732020-04-02  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
1674
1675	Turn the 'insert_point' and 'remove_point' linux target ops into
1676	methods of linux_process_target.
1677
1678	* linux-low.h (struct linux_target_ops): Remove the ops.
1679	(class linux_process_target) <low_insert_point>
1680	<low_remove_point>: Declare.
1681	* linux-low.cc (linux_process_target::low_insert_point)
1682	(linux_process_target::low_remove_point): Define.
1683	(linux_process_target::insert_point)
1684	(linux_process_target::remove_point): Update for calls to
1685	low_insert_point and low_remove_point.
1686	* linux-x86-low.cc (class x86_target) <low_insert_point>
1687	<low_remove_point>: Declare.
1688	(x86_insert_point): Turn into...
1689	(x86_target::low_insert_point): ...this.
1690	(x86_remove_point): Turn into...
1691	(x86_target::low_remove_point): ...this.
1692	(the_low_target): Remove the op fields.
1693	* linux-aarch64-low.cc (class aarch64_target) <low_insert_point>
1694	<low_remove_point>: Declare.
1695	(aarch64_insert_point): Turn into...
1696	(aarch64_target::low_insert_point): ...this.
1697	(aarch64_remove_point): Turn into...
1698	(aarch64_target::low_remove_point): ...this.
1699	(the_low_target): Remove the op fields.
1700	* linux-arm-low.cc (class arm_target) <low_insert_point>
1701	<low_remove_point>: Declare.
1702	(arm_insert_point): Turn into...
1703	(arm_target::low_insert_point): ...this.
1704	(arm_remove_point): Turn into...
1705	(arm_target::low_remove_point): ...this.
1706	(the_low_target): Remove the op fields.
1707	* linux-crisv32-low.cc (class crisv32_target) <low_insert_point>
1708	<low_remove_point>: Declare.
1709	(crisv32_insert_point): Turn into...
1710	(crisv32_target::low_insert_point): ...this.
1711	(crisv32_remove_point): Turn into...
1712	(crisv32_target::low_remove_point): ...this.
1713	(the_low_target): Remove the op fields.
1714	* linux-mips-low.cc (class mips_target) <low_insert_point>
1715	<low_remove_point>: Declare.
1716	(mips_insert_point): Turn into...
1717	(mips_target::low_insert_point): ...this.
1718	(mips_remove_point): Turn into...
1719	(mips_target::low_remove_point): ...this.
1720	(the_low_target): Remove the op fields.
1721	* linux-ppc-low.cc (class ppc_target) <low_insert_point>
1722	<low_remove_point>: Declare.
1723	(ppc_insert_point): Turn into...
1724	(ppc_target::low_insert_point): ...this.
1725	(ppc_remove_point): Turn into...
1726	(ppc_target::low_remove_point): ...this.
1727	(the_low_target): Remove the op fields.
1728	* linux-bfin-low.cc (the_low_target): Remove the op fields.
1729	* linux-m32r-low.cc (the_low_target): Ditto.
1730	* linux-m68k-low.cc (the_low_target): Ditto.
1731	* linux-s390-low.cc (the_low_target): Ditto.
1732	* linux-sh-low.cc (the_low_target): Ditto.
1733	* linux-sparc-low.cc (the_low_target): Ditto.
1734	* linux-tic6x-low.cc (the_low_target): Ditto.
1735	* linux-tile-low.cc (the_low_target): Ditto.
1736	* linux-xtensa-low.cc (the_low_target): Ditto.
1737
17382020-04-02  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
1739
1740	Remove the 'supports_z_point_type' linux target op and let the
1741	concrete linux target define it by overriding the op declared in
1742	process_stratum_target.
1743
1744	* linux-low.cc (linux_process_target::supports_z_point_type):
1745	Remove.
1746	* linux-low.h (struct linux_target_ops): Remove the op.
1747	(class linux_process_target) <supports_z_point_type>: Remove.
1748	* linux-x86-low.cc (class x86_target) <supports_z_point_type>:
1749	Declare.
1750	(x86_supports_z_point_type): Turn into...
1751	(x86_target::supports_z_point_type): ...this.
1752	(the_low_target): Remove the op field.
1753	* linux-aarch64-low.cc (class aarch64_target)
1754	<supports_z_point_type>: Declare.
1755	(aarch64_supports_z_point_type): Turn into...
1756	(aarch64_target::supports_z_point_type): ...this.
1757	(the_low_target): Remove the op field.
1758	* linux-arm-low.cc (class arm_target) <supports_z_point_type>:
1759	Declare.
1760	(arm_supports_z_point_type): Turn into...
1761	(arm_target::supports_z_point_type): ...this.
1762	(the_low_target): Remove the op field.
1763	* linux-crisv32-low.cc (class crisv32_target)
1764	<supports_z_point_type>: Declare.
1765	(cris_supports_z_point_type): Turn into...
1766	(crisv32_target::supports_z_point_type): ...this.
1767	(the_low_target): Remove the op field.
1768	* linux-mips-low.cc (class mips_target) <supports_z_point_type>:
1769	Declare.
1770	(mips_supports_z_point_type): Turn into...
1771	(mips_target::supports_z_point_type): ...this.
1772	(the_low_target): Remove the op field.
1773	* linux-ppc-low.cc (class ppc_target) <supports_z_point_type>:
1774	Declare.
1775	(ppc_supports_z_point_type): Turn into...
1776	(ppc_target::supports_z_point_type): ...this.
1777	(the_low_target): Remove the op field.
1778	* linux-s390-low.cc (class s390_target) <supports_z_point_type>:
1779	Declare.
1780	(s390_supports_z_point_type): Turn into...
1781	(s390_target::supports_z_point_type): ...this.
1782	(the_low_target): Remove the op field.
1783	* linux-bfin-low.cc (the_low_target): Remove the op field.
1784	* linux-m32r-low.cc (the_low_target): Ditto.
1785	* linux-m68k-low.cc (the_low_target): Ditto.
1786	* linux-sh-low.cc (the_low_target): Ditto.
1787	* linux-sparc-low.cc (the_low_target): Ditto.
1788	* linux-tic6x-low.cc (the_low_target): Ditto.
1789	* linux-tile-low.cc (the_low_target): Ditto.
1790	* linux-xtensa-low.cc (the_low_target): Ditto.
1791
17922020-04-02  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
1793
1794	Turn the 'breakpoint_at' linux target op into a method of
1795	linux_process_target.
1796
1797	* linux-low.h (struct linux_target_ops): Remove the op.
1798	(class linux_process_target) <low_breakpoint_at>: Declare.
1799
1800	Update the callers below:
1801
1802	* linux-low.cc (linux_process_target::save_stop_reason)
1803	(linux_process_target::thread_still_has_status_pending)
1804	(linux_process_target::wait_1)
1805
1806	* linux-x86-low.cc (class x86_target)
1807	<low_breakpoint_at>: Declare.
1808	(x86_breakpoint_at): Turn into...
1809	(x86_target::low_breakpoint_at): ...this.
1810	(the_low_target): Remove the op field.
1811	* linux-aarch64-low.cc (class aarch64_target)
1812	<low_breakpoint_at>: Declare.
1813	(aarch64_breakpoint_at): Turn into...
1814	(aarch64_target::low_breakpoint_at): ...this.
1815	(the_low_target): Remove the op field.
1816	* linux-arm-low.cc (class arm_target)
1817	<low_breakpoint_at>: Declare.
1818	(arm_target::low_breakpoint_at): Define.
1819	(the_low_target): Remove the op field.
1820	* linux-bfin-low.cc (class bfin_target)
1821	<low_breakpoint_at>: Declare.
1822	(bfin_breakpoint_at): Turn into...
1823	(bfin_target::low_breakpoint_at): ...this.
1824	(the_low_target): Remove the op field.
1825	* linux-cris-low.cc (class cris_target)
1826	<low_breakpoint_at>: Declare.
1827	(cris_breakpoint_at): Turn into...
1828	(cris_target::low_breakpoint_at): ...this.
1829	(the_low_target): Remove the op field.
1830	* linux-crisv32-low.cc (class crisv32_target)
1831	<low_breakpoint_at>: Declare.
1832	(crisv32_breakpoint_at): Turn into...
1833	(crisv32_target::low_breakpoint_at): ...this.
1834	(the_low_target): Remove the op field.
1835	* linux-ia64-low.cc (class ia64_target)
1836	<low_breakpoint_at>: Declare.
1837	(ia64_target::low_breakpoint_at): Define.
1838	* linux-m32r-low.cc (class m32r_target)
1839	<low_breakpoint_at>: Declare.
1840	(m32r_breakpoint_at): Turn into...
1841	(m32r_target::low_breakpoint_at): ...this.
1842	(the_low_target): Remove the op field.
1843	* linux-m68k-low.cc (class m68k_target)
1844	<low_breakpoint_at>: Declare.
1845	(m68k_breakpoint_at): Turn into...
1846	(m68k_target::low_breakpoint_at): ...this.
1847	(the_low_target): Remove the op field.
1848	* linux-mips-low.cc (class mips_target)
1849	<low_breakpoint_at>: Declare.
1850	(mips_breakpoint_at): Turn into...
1851	(mips_target::low_breakpoint_at): ...this.
1852	(the_low_target): Remove the op field.
1853	* linux-nios2-low.cc (class nios2_target)
1854	<low_breakpoint_at>: Declare.
1855	(nios2_breakpoint_at): Turn into...
1856	(nios2_target::low_breakpoint_at): ...this.
1857	(the_low_target): Remove the op field.
1858	* linux-ppc-low.cc (class ppc_target)
1859	<low_breakpoint_at>: Declare.
1860	(ppc_breakpoint_at): Turn into...
1861	(ppc_target::low_breakpoint_at): ...this.
1862	(the_low_target): Remove the op field.
1863	* linux-riscv-low.cc (class riscv_target)
1864	<low_breakpoint_at>: Declare.
1865	(riscv_breakpoint_at): Turn into...
1866	(riscv_target::low_breakpoint_at): ...this.
1867	(the_low_target): Remove the op field.
1868	* linux-s390-low.cc (class s390_target)
1869	<low_breakpoint_at>: Declare.
1870	(s390_breakpoint_at): Turn into...
1871	(s390_target::low_breakpoint_at): ...this.
1872	(the_low_target): Remove the op field.
1873	* linux-sh-low.cc (class sh_target)
1874	<low_breakpoint_at>: Declare.
1875	(sh_breakpoint_at): Turn into...
1876	(sh_target::low_breakpoint_at): ...this.
1877	(the_low_target): Remove the op field.
1878	* linux-sparc-low.cc (class sparc_target)
1879	<low_breakpoint_at>: Declare.
1880	(sparc_breakpoint_at): Turn into...
1881	(sparc_target::low_breakpoint_at): ...this.
1882	(the_low_target): Remove the op field.
1883	* linux-tic6x-low.cc (class tic6x_target)
1884	<low_breakpoint_at>: Declare.
1885	(tic6x_breakpoint_at): Turn into...
1886	(tic6x_target::low_breakpoint_at): ...this.
1887	(the_low_target): Remove the op field.
1888	* linux-tile-low.cc (class tile_target)
1889	<low_breakpoint_at>: Declare.
1890	(tile_breakpoint_at): Turn into...
1891	(tile_target::low_breakpoint_at): ...this.
1892	(the_low_target): Remove the op field.
1893	* linux-xtensa-low.cc (class xtensa_target)
1894	<low_breakpoint_at>: Declare.
1895	(xtensa_breakpoint_at): Turn into...
1896	(xtensa_target::low_breakpoint_at): ...this.
1897	(the_low_target): Remove the op field.
1898
18992020-04-02  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
1900
1901	Turn the 'decr_pc_after_break' linux_target_ops field into
1902	a method of linux_process_target.
1903
1904	* linux-low.h (struct linux_target_ops)
1905	<decr_pc_after_break>: Remove.
1906	(class linux_process_target) <low_decr_pc_after_break>: New method
1907	declaration.
1908	* linux-low.cc (linux_process_target::low_decr_pc_after_break):
1909	New method implementation.
1910
1911	Update the users below.
1912
1913	(linux_process_target::save_stop_reason)
1914	(linux_process_target::wait_1)
1915	* linux-x86-low.cc (class x86_target) <low_decr_pc_after_break>:
1916	New declaration.
1917	(x86_target::low_decr_pc_after_break): New method implementation.
1918	(the_low_target): Remove the field.
1919	* linux-bfin-low.cc (class bfin_target) <low_decr_pc_after_break>:
1920	New declaration.
1921	(bfin_target::low_decr_pc_after_break): New method implementation.
1922	(the_low_target): Remove the field.
1923	* linux-m68k-low.cc (class m68k_target) <low_decr_pc_after_break>:
1924	New declaration.
1925	(m68k_target::low_decr_pc_after_break): New method implementation.
1926	(the_low_target): Remove the field.
1927	* linux-s390-low.cc (class s390_target) <low_decr_pc_after_break>:
1928	New declaration.
1929	(s390_target::low_decr_pc_after_break): New method implementation.
1930	(the_low_target): Remove the field.
1931	* linux-aarch64-low.cc (the_low_target): Remove the field.
1932	* linux-arm-low.cc (the_low_target): Remove the field.
1933	* linux-cris-low.cc (the_low_target): Remove the field.
1934	* linux-crisv32-low.cc (the_low_target): Remove the field.
1935	* linux-m32r-low.cc (the_low_target): Remove the field.
1936	* linux-mips-low.cc (the_low_target): Remove the field.
1937	* linux-nios2-low.cc (the_low_target): Remove the field.
1938	* linux-ppc-low.cc (the_low_target): Remove the field.
1939	* linux-riscv-low.cc (the_low_target): Remove the field.
1940	* linux-sh-low.cc (the_low_target): Remove the field.
1941	* linux-sparc-low.cc (the_low_target): Remove the field.
1942	* linux-tic6x-low.cc (the_low_target): Remove the field.
1943	* linux-tile-low.cc (the_low_target): Remove the field.
1944	* linux-xtensa-low.cc (the_low_target): Remove the field.
1945
19462020-04-02  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
1947
1948	Remove the 'supports_software_single_step' linux target op and let
1949	the concrete linux target define it by overriding the op in
1950	process_stratum_target.
1951	Turn the 'get_next_pcs' linux target op into a method of
1952	linux_process_target.
1953
1954	* linux-low.h (struct linux_target_ops): Remove the ops.
1955	(class linux_process_target) <supports_software_single_step>:
1956	Remove.
1957	<low_get_next_pcs>: Declare.
1958	* linux-low.cc (can_software_single_step): Remove.
1959	(linux_process_target::low_get_next_pcs): Define.
1960	(linux_process_target::supports_software_single_step): Remove.
1961
1962	Update the callers below.
1963
1964	(linux_process_target::handle_extended_wait)
1965	(linux_process_target::wait_1)
1966	(linux_process_target::install_software_single_step_breakpoints)
1967	(linux_process_target::single_step)
1968	(linux_process_target::thread_needs_step_over)
1969	(linux_process_target::proceed_one_lwp)
1970	(linux_process_target::supports_range_stepping)
1971
1972	* linux-x86-low.cc (the_low_target): Remove the op field.
1973	* linux-aarch64-low.cc (the_low_target): Ditto.
1974	* linux-bfin-low.cc (the_low_target): Ditto.
1975	* linux-cris-low.cc (the_low_target): Ditto.
1976	* linux-crisv32-low.cc (the_low_target): Ditto.
1977	* linux-m32r-low.cc (the_low_target): Ditto.
1978	* linux-m68k-low.cc (the_low_target): Ditto.
1979	* linux-mips-low.cc (the_low_target): Ditto.
1980	* linux-nios2-low.cc (the_low_target): Ditto.
1981	* linux-ppc-low.cc (the_low_target): Ditto.
1982	* linux-riscv-low.cc (the_low_target): Ditto.
1983	* linux-s390-low.cc (the_low_target): Ditto.
1984	* linux-sh-low.cc (the_low_target): Ditto.
1985	* linux-sparc-low.cc (the_low_target): Ditto.
1986	* linux-tic6x-low.cc (the_low_target): Ditto.
1987	* linux-tile-low.cc (the_low_target): Ditto.
1988	* linux-xtensa-low.cc (the_low_target): Ditto.
1989	* linux-arm-low.cc (class arm_target) <low_get_next_pcs>
1990	<supports_software_single_step>: Declare.
1991	(arm_target::supports_software_single_step): Define.
1992	(arm_gdbserver_get_next_pcs): Turn into...
1993	(arm_target::low_get_next_pcs): ...this.
1994	(the_low_target): Remove the op field.
1995
19962020-04-02  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
1997
1998	Remove the 'sw_breakpoint_from_kind' linux target op, and let
1999	the concrete linux target define it by overriding the op
2000	in process_stratum_target.
2001
2002	* linux-low.cc (linux_process_target::sw_breakpoint_from_kind):
2003	Remove.
2004	* linux-low.h (struct linux_target_ops): Remove the op.
2005	(class linux_process_target) <sw_breakpoint_from_kind>: Remove.
2006	* linux-x86-low.cc (class x86_target) <sw_breakpoint_from_kind>:
2007	Declare.
2008	(x86_sw_breakpoint_from_kind): Turn into...
2009	(x86_target::sw_breakpoint_from_kind): ...this.
2010	(the_low_target): Remove the op field.
2011	* linux-aarch64-low.cc (class aarch64_target)
2012	<sw_breakpoint_from_kind>: Declare.
2013	(aarch64_sw_breakpoint_from_kind): Turn into...
2014	(aarch64_target::sw_breakpoint_from_kind): ...this.
2015	(the_low_target): Remove the op field.
2016	* linux-arm-low.cc (class arm_target) <sw_breakpoint_from_kind>:
2017	Declare.
2018	(arm_target::sw_breakpoint_from_kind): Define.
2019	(the_low_target): Remove the op field.
2020	* linux-bfin-low.cc (class bfin_target) <sw_breakpoint_from_kind>:
2021	Declare.
2022	(bfin_sw_breakpoint_from_kind): Turn into...
2023	(bfin_target::sw_breakpoint_from_kind): ...this.
2024	(the_low_target): Remove the op field.
2025	* linux-cris-low.cc (class cris_target) <sw_breakpoint_from_kind>:
2026	Declare.
2027	(cris_sw_breakpoint_from_kind): Turn into...
2028	(cris_target::sw_breakpoint_from_kind): ...this.
2029	(the_low_target): Remove the op field.
2030	* linux-crisv32-low.cc (class crisv32_target)
2031	<sw_breakpoint_from_kind>: Declare.
2032	(cris_sw_breakpoint_from_kind): Turn into...
2033	(crisv32_target::sw_breakpoint_from_kind): ...this.
2034	(the_low_target): Remove the op field.
2035	* linux-ia64-low.cc (class ia64_target) <sw_breakpoint_from_kind>:
2036	Declare.
2037	(ia64_target::sw_breakpoint_from_kind): Define.
2038	* linux-m32r-low.cc (class m32r_target) <sw_breakpoint_from_kind>:
2039	Declare.
2040	(m32r_sw_breakpoint_from_kind): Turn into...
2041	(m32r_target::sw_breakpoint_from_kind): ...this.
2042	(the_low_target): Remove the op field.
2043	* linux-m68k-low.cc (class m68k_target) <sw_breakpoint_from_kind>:
2044	Declare.
2045	(m68k_sw_breakpoint_from_kind): Turn into...
2046	(m68k_target::sw_breakpoint_from_kind): ...this.
2047	(the_low_target): Remove the op field.
2048	* linux-mips-low.cc (class mips_target) <sw_breakpoint_from_kind>:
2049	Declare.
2050	(mips_sw_breakpoint_from_kind): Turn into...
2051	(mips_target::sw_breakpoint_from_kind): ...this.
2052	(the_low_target): Remove the op field.
2053	* linux-nios2-low.cc (class nios2_target) <sw_breakpoint_from_kind>:
2054	Declare.
2055	(nios2_sw_breakpoint_from_kind): Turn into...
2056	(nios2_target::sw_breakpoint_from_kind): ...this.
2057	(the_low_target): Remove the op field.
2058	* linux-ppc-low.cc (class ppc_target) <sw_breakpoint_from_kind>:
2059	Declare.
2060	(ppc_sw_breakpoint_from_kind): Turn into...
2061	(ppc_target::sw_breakpoint_from_kind): ...this.
2062	(the_low_target): Remove the op field.
2063	* linux-riscv-low.cc (class riscv_target) <sw_breakpoint_from_kind>:
2064	Declare.
2065	(riscv_sw_breakpoint_from_kind): Turn into...
2066	(riscv_target::sw_breakpoint_from_kind): ...this.
2067	(the_low_target): Remove the op field.
2068	* linux-s390-low.cc (class s390_target) <sw_breakpoint_from_kind>:
2069	Declare.
2070	(s390_sw_breakpoint_from_kind): Turn into...
2071	(s390_target::sw_breakpoint_from_kind): ...this.
2072	(the_low_target): Remove the op field.
2073	* linux-sh-low.cc (class sh_target) <sw_breakpoint_from_kind>:
2074	Declare.
2075	(sh_sw_breakpoint_from_kind): Turn into...
2076	(sh_target::sw_breakpoint_from_kind): ...this.
2077	(the_low_target): Remove the op field.
2078	* linux-sparc-low.cc (class sparc_target) <sw_breakpoint_from_kind>:
2079	Declare.
2080	(sparc_sw_breakpoint_from_kind): Turn into...
2081	(sparc_target::sw_breakpoint_from_kind): ...this.
2082	(the_low_target): Remove the op field.
2083	* linux-tic6x-low.cc (class tic6x_target) <sw_breakpoint_from_kind>:
2084	Declare.
2085	(tic6x_sw_breakpoint_from_kind): Turn into...
2086	(tic6x_target::sw_breakpoint_from_kind): ...this.
2087	(the_low_target): Remove the op field.
2088	* linux-tile-low.cc (class tile_target) <sw_breakpoint_from_kind>:
2089	Declare.
2090	(tile_sw_breakpoint_from_kind): Turn into...
2091	(tile_target::sw_breakpoint_from_kind): ...this.
2092	(the_low_target): Remove the op field.
2093	* linux-xtensa-low.cc (class xtensa_target)
2094	<sw_breakpoint_from_kind>: Declare.
2095	(xtensa_sw_breakpoint_from_kind): Turn into...
2096	(xtensa_target::sw_breakpoint_from_kind): ...this.
2097	(the_low_target): Remove the op field.
2098
20992020-04-02  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
2100
2101	Remove the 'breakpoint_kind_from_pc' and
2102	'breakpoint_kind_from_current_state' linux target ops, and let the
2103	concrete linux target define them by overriding the ops of
2104	process_stratum_target.
2105
2106	* linux-low.cc (linux_process_target::breakpoint_kind_from_pc):
2107	Remove.
2108	(linux_process_target::breakpoint_kind_from_current_state): Remove.
2109	* linux-low.h (struct linux_target_ops): Remove ops.
2110	(class linux_process_target) <breakpoint_kind_from_pc>: Remove.
2111	<breakpoint_kind_from_current_state>: Remove.
2112	* linux-x86-low.cc (the_low_target): Remove the op fields.
2113	* linux-bfin-low.cc (the_low_target): Ditto.
2114	* linux-cris-low.cc (the_low_target): Ditto.
2115	* linux-crisv32-low.cc (the_low_target): Ditto.
2116	* linux-m32r-low.cc (the_low_target): Ditto.
2117	* linux-m68k-low.cc (the_low_target): Ditto.
2118	* linux-mips-low.cc (the_low_target): Ditto.
2119	* linux-nios2-low.cc (the_low_target): Ditto.
2120	* linux-ppc-low.cc (the_low_target): Ditto.
2121	* linux-s390-low.cc (the_low_target): Ditto.
2122	* linux-sh-low.cc (the_low_target): Ditto.
2123	* linux-sparc-low.cc (the_low_target): Ditto.
2124	* linux-tic6x-low.cc (the_low_target): Ditto.
2125	* linux-tile-low.cc (the_low_target): Ditto.
2126	* linux-xtensa-low.cc (the_low_target): Ditto.
2127	* linux-aarch64-low.cc (class aarch64_target)
2128	<breakpoint_kind_from_pc>
2129	<breakpoint_kind_from_current_state>: Declare.
2130	(aarch64_breakpoint_kind_from_pc): Turn into...
2131	(aarch64_target::breakpoint_kind_from_pc): ...this.
2132	(aarch64_breakpoint_kind_from_current_state): Turn into...
2133	(aarch64_target::breakpoint_kind_from_current_state): ...this.
2134	(the_low_target): Remove the op fields.
2135	* linux-arm-low.cc (class arm_target):
2136	<breakpoint_kind_from_pc>
2137	<breakpoint_kind_from_current_state>: Declare.
2138	(arm_target::breakpoint_kind_from_pc): Define.
2139	(arm_target::breakpoint_kind_from_current_state): Define.
2140	(the_low_target): Remove the op fields.
2141	* linux-riscv-low.cc (class riscv_target):
2142	<breakpoint_kind_from_pc>: Declare.
2143	(riscv_breakpoint_kind_from_pc): Turn into...
2144	(riscv_target::breakpoint_kind_from_pc): ...this.
2145	(the_low_target): Remove the op fields.
2146
21472020-04-02  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
2148
2149	Turn the 'get_pc' and 'set_pc' linux target ops into methods
2150	of linux_process_target.
2151
2152	* linux-low.h (struct linux_target_ops): Remove the ops.
2153	(class linux_process_target) <low_supports_breakpoints>
2154	<low_get_pc>
2155	<low_set_pc>: Declare.
2156	* linux-low.cc (supports_breakpoints): Turn into...
2157	(linux_process_target::low_supports_breakpoints): ...this.
2158	(linux_process_target::low_get_pc): Define.
2159	(linux_process_target::low_set_pc): Define.
2160
2161	Update the callers below.
2162
2163	(linux_process_target::get_pc)
2164	(linux_process_target::save_stop_reason)
2165	(linux_process_target::maybe_move_out_of_jump_pad)
2166	(linux_process_target::wait_1)
2167	(linux_process_target::resume_one_lwp_throw)
2168	(linux_process_target::resume)
2169	(linux_process_target::proceed_all_lwps)
2170	(linux_process_target::read_pc)
2171	(linux_process_target::write_pc)
2172
2173	* linux-x86-low.cc (class linux_process_target)
2174	<low_supports_breakpoints>
2175	<low_get_pc>
2176	<low_set_pc>: Declare.
2177	(x86_target::low_supports_breakpoints): Define.
2178	(x86_get_pc): Turn into...
2179	(x86_target::low_get_pc): ...this.
2180	(x86_set_pc): Turn into...
2181	(x86_target::low_set_pc): ...this.
2182	(the_low_target): Remove the op fields.
2183	* linux-arm-low.cc (class arm_target)
2184	<low_supports_breakpoints>
2185	<low_get_pc>
2186	<low_set_pc>: Declare.
2187	(arm_target::low_supports_breakpoints)
2188	(arm_target::low_get_pc)
2189	(arm_target::low_set_pc): Define.
2190	(the_low_target): Remove the op fields.
2191	* linux-bfin-low.cc (class bfin_target)
2192	<low_supports_breakpoints>
2193	<low_get_pc>
2194	<low_set_pc>: Declare.
2195	(bfin_target::low_supports_breakpoints)
2196	(bfin_target::low_get_pc)
2197	(bfin_target::low_set_pc): Define.
2198	(the_low_target): Remove the op fields.
2199	* linux-cris-low.cc (class cris_target)
2200	<low_supports_breakpoints>
2201	<low_get_pc>
2202	<low_set_pc>: Declare.
2203	(cris_target::low_supports_breakpoints)
2204	(cris_target::low_get_pc)
2205	(cris_target::low_set_pc): Define.
2206	(the_low_target): Remove the op fields.
2207	* linux-crisv32-low.cc (class crisv32_target)
2208	<low_supports_breakpoints>
2209	<low_get_pc>
2210	<low_set_pc>: Declare.
2211	(crisv32_target::low_supports_breakpoints)
2212	(crisv32_target::low_get_pc)
2213	(crisv32_target::low_set_pc): Define.
2214	(the_low_target): Remove the op fields.
2215	* linux-m32r-low.cc (class m32r_target)
2216	<low_supports_breakpoints>
2217	<low_get_pc>
2218	<low_set_pc>: Declare.
2219	(m32r_target::low_supports_breakpoints)
2220	(m32r_target::low_get_pc)
2221	(m32r_target::low_set_pc): Define.
2222	(the_low_target): Remove the op fields.
2223	* linux-m68k-low.cc (class m68k_target)
2224	<low_supports_breakpoints>
2225	<low_get_pc>
2226	<low_set_pc>: Declare.
2227	(m68k_target::low_supports_breakpoints)
2228	(m68k_target::low_get_pc)
2229	(m68k_target::low_set_pc): Define.
2230	(the_low_target): Remove the op fields.
2231	* linux-nios2-low.cc (class nios2_target)
2232	<low_supports_breakpoints>
2233	<low_get_pc>
2234	<low_set_pc>: Declare.
2235	(nios2_target::low_supports_breakpoints)
2236	(nios2_target::low_get_pc)
2237	(nios2_target::low_set_pc): Define.
2238	(the_low_target): Remove the op fields.
2239	* linux-sh-low.cc (class sh_target)
2240	<low_supports_breakpoints>
2241	<low_get_pc>
2242	<low_set_pc>: Declare.
2243	(sh_target::low_supports_breakpoints)
2244	(sh_target::low_get_pc)
2245	(sh_target::low_set_pc): Define.
2246	(the_low_target): Remove the op fields.
2247	* linux-xtensa-low.cc (class xtensa_target)
2248	<low_supports_breakpoints>
2249	<low_get_pc>
2250	<low_set_pc>: Declare.
2251	(xtensa_target::low_supports_breakpoints)
2252	(xtensa_target::low_get_pc)
2253	(xtensa_target::low_set_pc): Define.
2254	(the_low_target): Remove the op fields.
2255	* linux-sparc-low.cc (class sparc_target)
2256	<low_supports_breakpoints>
2257	<low_get_pc>: Declare.
2258	(sparc_target::low_supports_breakpoints)
2259	(sparc_target::low_get_pc): Define.
2260	(the_low_target): Remove the op fields.
2261	* linux-tile-low.cc (class tile_target)
2262	<low_supports_breakpoints>
2263	<low_get_pc>
2264	<low_set_pc>: Declare.
2265	(tile_target::low_supports_breakpoints)
2266	(tile_target::low_get_pc)
2267	(tile_target::low_set_pc): Define.
2268	(the_low_target): Remove the op fields.
2269	* linux-aarch64-low.cc (class aarch64_target)
2270	<low_supports_breakpoints>
2271	<low_get_pc>
2272	<low_set_pc>: Declare.
2273	(aarch64_target::low_supports_breakpoints): Define.
2274	(aarch64_get_pc): Turn into...
2275	(aarch64_target::low_get_pc): ...this.
2276	(aarch64_set_pc): Turn into...
2277	(aarch64_target::low_set_pc): ...this.
2278	(the_low_target): Remove the op fields.
2279	* linux-mips-low.cc (class mips_target)
2280	<low_supports_breakpoints>
2281	<low_get_pc>
2282	<low_set_pc>: Declare.
2283	(mips_target::low_supports_breakpoints): Define.
2284	(mips_get_pc): Turn into...
2285	(mips_target::low_get_pc): ...this.
2286	(mips_set_pc): Turn into...
2287	(mips_target::low_set_pc): ...this.
2288	(the_low_target): Remove the op fields.
2289	* linux-ppc-low.cc (class ppc_target)
2290	<low_supports_breakpoints>
2291	<low_get_pc>
2292	<low_set_pc>: Declare.
2293	(ppc_target::low_supports_breakpoints): Define.
2294	(ppc_get_pc): Turn into...
2295	(ppc_target::low_get_pc): ...this.
2296	(ppc_set_pc): Turn into...
2297	(ppc_target::low_set_pc): ...this.
2298	(the_low_target): Remove the op fields.
2299	* linux-riscv-low.cc (class riscv_target)
2300	<low_supports_breakpoints>
2301	<low_get_pc>
2302	<low_set_pc>: Declare.
2303	(riscv_target::low_supports_breakpoints): Define.
2304	(riscv_get_pc): Turn into...
2305	(riscv_target::low_get_pc): ...this.
2306	(riscv_set_pc): Turn into...
2307	(riscv_target::low_set_pc): ...this.
2308	(the_low_target): Remove the op fields.
2309	* linux-s390-low.cc (class s390_target)
2310	<low_supports_breakpoints>
2311	<low_get_pc>
2312	<low_set_pc>: Declare.
2313	(s390_target::low_supports_breakpoints): Define.
2314	(s390_get_pc): Turn into...
2315	(s390_target::low_get_pc): ...this.
2316	(s390_set_pc): Turn into...
2317	(s390_target::low_set_pc): ...this.
2318	(the_low_target): Remove the op fields.
2319	* linux-tic6x-low.cc (class tic6x_target)
2320	<low_supports_breakpoints>
2321	<low_get_pc>
2322	<low_set_pc>: Declare.
2323	(tic6x_target::low_supports_breakpoints): Define.
2324	(tic6x_get_pc): Turn into...
2325	(tic6x_target::low_get_pc): ...this.
2326	(tic6x_set_pc): Turn into...
2327	(tic6x_target::low_set_pc): ...this.
2328	(the_low_target): Remove the op fields.
2329
23302020-04-02  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
2331
2332	Turn some more static methods in linux-low into private methods
2333	of linux_process_target.
2334
2335	* linux-low.cc (get_pc): Turn into...
2336	(linux_process_target::get_pc): ...this.
2337	(save_stop_reason): Turn into...
2338	(linux_process_target::save_stop_reason): ...this.
2339	(thread_still_has_status_pending_p): Turn into...
2340	(linux_process_target::thread_still_has_status_pending): ...this.
2341	(status_pending_p_callback): Turn into...
2342	(linux_process_target::status_pending_p_callback): ...this.
2343	(resume_stopped_resumed_lwps): Turn into...
2344	(linux_process_target::resume_stopped_resumed_lwps): ...this.
2345	(install_software_single_step_breakpoints): Turn into...
2346	(linux_process_target::install_software_single_step_breakpoints):
2347	...this.
2348	(single_step): Turn into...
2349	(linux_process_target::single_step): ...this.
2350	(linux_resume_one_lwp_throw): Turn into...
2351	(linux_process_target::resume_one_lwp_throw): ...this.
2352	(linux_resume_one_lwp): Turn into...
2353	(linux_process_target::resume_one_lwp): ...this.
2354	(resume_status_pending_p): Turn into...
2355	(linux_process_target::resume_status_pending): ...this.
2356	(need_step_over_p): Turn into...
2357	(linux_process_target::thread_needs_step_over): ...this.
2358	(linux_resume_one_thread): Turn into...
2359	(linux_process_target::resume_one_thread): ...this.
2360	(proceed_one_lwp): Turn into...
2361	(linux_process_target::proceed_one_lwp): ...this.
2362	(unsuspend_and_proceed_one_lwp): Turn into...
2363	(linux_process_target::unsuspend_and_proceed_one_lwp): ...this.
2364
2365	Update the calls/references to the above functions below.
2366
2367	(linux_process_target::handle_extended_wait)
2368	(linux_process_target::filter_event)
2369	(linux_process_target::wait_for_event_filtered)
2370	(linux_process_target::wait_1)
2371	(linux_process_target::move_out_of_jump_pad)
2372	(linux_process_target::start_step_over)
2373	(linux_process_target::resume)
2374	(linux_process_target::proceed_all_lwps)
2375	(regsets_store_inferior_registers)
2376	(linux_process_target::store_register)
2377
2378	* linux-low.h (class linux_process_target)
2379	<get_pc>
2380	<save_stop_reason>
2381	<thread_still_has_status_pending>
2382	<status_pending_p_callback>
2383	<resume_stopped_resumed_lwps>
2384	<install_software_single_step_breakpoints>
2385	<single_step>
2386	<resume_one_lwp_throw>
2387	<resume_one_lwp>
2388	<resume_status_pending>
2389	<thread_needs_step_over>
2390	<resume_one_thread>
2391	<proceed_one_lwp>
2392	<unsuspend_and_proceed_one_lwp>: Declare.
2393
23942020-04-02  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
2395
2396	Turn the 'fetch_register' linux target op into a method of
2397	linux_process_target.
2398
2399	* linux-low.h (struct linux_target_ops) <fetch_register>: Remove.
2400	(class linux_process_target) <low_fetch_register>: Declare.
2401	* linux-x86-low.cc (the_low_target)
2402	* linux-aarch64-low.cc (the_low_target)
2403	* linux-arm-low.cc (the_low_target)
2404	* linux-bfin-low.cc (the_low_target)
2405	* linux-cris-low.cc (the_low_target)
2406	* linux-crisv32-low.cc (the_low_target)
2407	* linux-m32r-low.cc (the_low_target)
2408	* linux-m68k-low.cc (the_low_target)
2409	* linux-nios2-low.cc (the_low_target)
2410	* linux-ppc-low.cc (the_low_target)
2411	* linux-s390-low.cc (the_low_target)
2412	* linux-sh-low.cc (the_low_target)
2413	* linux-sparc-low.cc (the_low_target)
2414	* linux-tic6x-low.cc (the_low_target)
2415	* linux-tile-low.cc (the_low_target)
2416	* linux-xtensa-low.cc (the_low_target): Remove the op field.
2417	* linux-ia64-low.cc (class ia64_target) <low_fetch_register>:
2418	Declare.
2419	(ia64_fetch_register): Turn into...
2420	(ia64_target::low_fetch_register): ...this.
2421	(the_low_target): Remove the op field.
2422	* linux-mips-low.cc (class mips_target) <low_fetch_register>:
2423	Declare.
2424	(mips_fetch_register): Turn into...
2425	(mips_target::low_fetch_register): ...this.
2426	(the_low_target): Remove the op field.
2427	* linux-riscv-low.cc (class riscv_target) <low_fetch_register>:
2428	Declare.
2429	(riscv_fetch_register): Turn into...
2430	(riscv_target::low_fetch_register): ...this.
2431	(the_low_target): Remove the op field.
2432
2433	Update the callers below.
2434
2435	* linux-low.cc (linux_process_target::fetch_registers)
2436	(linux_process_target::low_fetch_register)
2437
24382020-04-02  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
2439
2440	Turn the 'cannot_fetch_register' and 'cannot_store_register'
2441	linux target ops into methods of linux_process_target.
2442
2443	* linux-low.h (struct linux_target_ops): Remove the low target ops.
2444	(class linux_process_target) <fetch_register>
2445	<store_register>
2446	<usr_fetch_inferior_registers>
2447	<usr_store_inferior_registers>
2448	<low_cannot_fetch_register>
2449	<low_cannot_fetch_register> Declare.
2450	* linux-low.cc (fetch_register): Turn into...
2451	(linux_process_target::fetch_register): ...this.
2452	(store_register): Turn into ...
2453	(linux_process_target::store_register): ...this.
2454	(usr_fetch_inferior_registers): Turn into...
2455	(linux_process_target::usr_fetch_inferior_registers): ...this.
2456	(usr_store_inferior_registers): Turn into...
2457	(linux_process_target::usr_store_inferior_registers): ...this.
2458	* linux-x86-low.cc (class x86_target)
2459	<low_cannot_fetch_register>
2460	<low_cannot_store_register>: Declare.
2461	(x86_cannot_store_register): Turn into...
2462	(x86_target::low_cannot_store_register): ...this.
2463	(x86_cannot_fetch_register): Turn into...
2464	(x86_target::low_cannot_fetch_register): ...this.
2465	(the_low_target): Remove the target op fields.
2466	* linux-aarch64-low.cc (class aarch64_target)
2467	<low_cannot_fetch_register>
2468	<low_cannot_store_register>: Declare.
2469	(aarch64_target::low_cannot_fetch_register)
2470	(aarch64_target::low_cannot_store_register): Define.
2471	(the_low_target): Remove the op fields.
2472	* linux-arm-low.cc (class arm_target)
2473	<low_cannot_fetch_register>
2474	<low_cannot_store_register>: Declare.
2475	(arm_cannot_fetch_register): Turn into...
2476	(arm_target::low_cannot_fetch_register): ...this.
2477	(arm_cannot_store_register): Turn into...
2478	(arm_target::low_cannot_store_register): ...this.
2479	(the_low_target): Remove the op fields.
2480	* linux-bfin-low.cc (class bfin_target)
2481	<low_cannot_fetch_register>
2482	<low_cannot_store_register>: Declare.
2483	(bfin_cannot_fetch_register): Turn into...
2484	(bfin_target::low_cannot_fetch_register): ...this.
2485	(bfin_cannot_store_register): Turn into...
2486	(bfin_target::low_cannot_store_register): ...this.
2487	(the_low_target): Remove the op fields.
2488	* linux-cris-low.cc (class cris_target)
2489	<low_cannot_fetch_register>
2490	<low_cannot_store_register>: Declare.
2491	(cris_cannot_fetch_register): Turn into...
2492	(cris_target::low_cannot_fetch_register): ...this.
2493	(cris_cannot_store_register): Turn into...
2494	(cris_target::low_cannot_store_register): ...this.
2495	(the_low_target): Remove the op fields.
2496	* linux-crisv32-low.cc (class crisv32_target)
2497	<low_cannot_fetch_register>
2498	<low_cannot_store_register>: Declare.
2499	(crisv32_target::low_cannot_fetch_register)
2500	(crisv32_target::low_cannot_store_register): Define.
2501	(the_low_target): Remove the op fields.
2502	* linux-ia64-low.cc (class ia64_target)
2503	<low_cannot_fetch_register>
2504	<low_cannot_store_register>: Declare.
2505	(ia64_cannot_fetch_register): Turn into...
2506	(ia64_target::low_cannot_fetch_register): ...this.
2507	(ia64_cannot_store_register): Turn into...
2508	(ia64_target::low_cannot_store_register): ...this.
2509	(the_low_target): Remove the op fields.
2510	* linux-m32r-low.cc (class m32r_target)
2511	<low_cannot_fetch_register>
2512	<low_cannot_store_register>: Declare.
2513	(m32r_cannot_fetch_register): Turn into...
2514	(m32r_target::low_cannot_fetch_register): ...this.
2515	(m32r_cannot_store_register): Turn into...
2516	(m32r_target::low_cannot_store_register): ...this.
2517	(the_low_target): Remove the op fields.
2518	* linux-m68k-low.cc (class m68k_target)
2519	<low_cannot_fetch_register>
2520	<low_cannot_store_register>: Declare.
2521	(m68k_cannot_fetch_register): Turn into...
2522	(m68k_target::low_cannot_fetch_register): ...this.
2523	(m68k_cannot_store_register): Turn into...
2524	(m68k_target::low_cannot_store_register): ...this.
2525	(the_low_target): Remove the op fields.
2526	* linux-mips-low.cc (class mips_target)
2527	<low_cannot_fetch_register>
2528	<low_cannot_store_register>: Declare.
2529	(mips_cannot_fetch_register): Turn into...
2530	(mips_target::low_cannot_fetch_register): ...this.
2531	(mips_cannot_store_register): Turn into...
2532	(mips_target::low_cannot_store_register): ...this.
2533	(get_usrregs_info): Inline at the call sites in
2534	low_cannot_fetch_register and low_cannot_store_register,
2535	and remove.
2536	(the_low_target): Remove the op fields.
2537	* linux-nios2-low.cc (class nios2_target)
2538	<low_cannot_fetch_register>
2539	<low_cannot_store_register>: Declare.
2540	(nios2_cannot_fetch_register): Turn into...
2541	(nios2_target::low_cannot_fetch_register): ...this.
2542	(nios2_cannot_store_register): Turn into...
2543	(nios2_target::low_cannot_store_register): ...this.
2544	(the_low_target): Remove the op fields.
2545	* linux-ppc-low.cc (class ppc_target)
2546	<low_cannot_fetch_register>
2547	<low_cannot_store_register>: Declare.
2548	(ppc_cannot_fetch_register): Turn into...
2549	(ppc_target::low_cannot_fetch_register): ...this.
2550	(ppc_cannot_store_register): Turn into...
2551	(ppc_target::low_cannot_store_register): ...this.
2552	(the_low_target): Remove the op fields.
2553	* linux-riscv-low.cc (class riscv_target)
2554	<low_cannot_fetch_register>
2555	<low_cannot_store_register>: Declare.
2556	(riscv_target::low_cannot_fetch_register)
2557	(riscv_target::low_cannot_store_register): Define.
2558	(the_low_target): Remove the op fields.
2559	* linux-s390-low.cc (class s390_target)
2560	<low_cannot_fetch_register>
2561	<low_cannot_store_register>: Declare.
2562	(s390_cannot_fetch_register): Turn into...
2563	(s390_target::low_cannot_fetch_register): ...this.
2564	(s390_cannot_store_register): Turn into...
2565	(s390_target::low_cannot_store_register): ...this.
2566	(the_low_target): Remove the op fields.
2567	* linux-sh-low.cc (class sh_target)
2568	<low_cannot_fetch_register>
2569	<low_cannot_store_register>: Declare.
2570	(sh_cannot_fetch_register): Turn into...
2571	(sh_target::low_cannot_fetch_register): ...this.
2572	(sh_cannot_store_register): Turn into...
2573	(sh_target::low_cannot_store_register): ...this.
2574	(the_low_target): Remove the op fields.
2575	* linux-sparc-low.cc (class sparc_target)
2576	<low_cannot_fetch_register>
2577	<low_cannot_store_register>: Declare.
2578	(sparc_cannot_fetch_register): Turn into...
2579	(sparc_target::low_cannot_fetch_register): ...this.
2580	(sparc_cannot_store_register): Turn into...
2581	(sparc_target::low_cannot_store_register): ...this.
2582	(the_low_target): Remove the op fields.
2583	* linux-tic6x-low.cc (class tic6x_target)
2584	<low_cannot_fetch_register>
2585	<low_cannot_store_register>: Declare.
2586	(tic6x_cannot_fetch_register): Turn into...
2587	(tic6x_target::low_cannot_fetch_register): ...this.
2588	(tic6x_cannot_store_register): Turn into...
2589	(tic6x_target::low_cannot_store_register): ...this.
2590	(the_low_target): Remove the op fields.
2591	* linux-tile-low.cc (class tile_target)
2592	<low_cannot_fetch_register>
2593	<low_cannot_store_register>: Declare.
2594	(tile_cannot_fetch_register): Turn into...
2595	(tile_target::low_cannot_fetch_register): ...this.
2596	(tile_cannot_store_register): Turn into...
2597	(tile_target::low_cannot_store_register): ...this.
2598	(the_low_target): Remove the op fields.
2599	* linux-xtensa-low.cc (class xtensa_target)
2600	<low_cannot_fetch_register>
2601	<low_cannot_store_register>: Declare.
2602	(xtensa_target::low_cannot_fetch_register)
2603	(xtensa_target::low_cannot_store_register): Define.
2604	(the_low_target): Remove the op fields.
2605
26062020-04-02  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
2607
2608	Turn the 'regs_info' linux target op into a method of
2609	linux_process_target.
2610
2611	* linux-low.h (struct linux_target_ops) <regs_info>: Remove.
2612	(class linux_process_target) <get_regs_info>: Define.
2613
2614	Update the callers below.
2615
2616	* linux-low.cc (linux_process_target::fetch_registers)
2617	(linux_process_target::store_registers)
2618	* proc-service.cc (gregset_info)
2619
2620	* linux-x86-low.cc (class x86_target) <get_regs_info>: Declare.
2621	(x86_linux_regs_info): Turn into ...
2622	(x86_target::get_regs_info): ...this.
2623	(the_low_target): Remove the op field.
2624	* linux-aarch64-low.cc (class aarch64_target) <get_regs_info>:
2625	Declare.
2626	(aarch64_regs_info): Turn into ...
2627	(aarch64_target::get_regs_info): ...this.
2628	(the_low_target): Remove the op field.
2629	* linux-arm-low.cc (class arm_target) <get_regs_info>: Declare.
2630	(arm_regs_info): Turn into ...
2631	(arm_target::get_regs_info): ...this.
2632	(the_low_target): Remove the op field.
2633	* linux-bfin-low.cc (class bfin_target) <get_regs_info>: Declare.
2634	(bfin_regs_info): Turn into ...
2635	(bfin_target::get_regs_info): ...this.
2636	(the_low_target): Remove the op field.
2637	* linux-cris-low.cc (class cris_target) <get_regs_info>: Declare.
2638	(cris_regs_info): Turn into ...
2639	(cris_target::get_regs_info): ...this.
2640	(the_low_target): Remove the op field.
2641	* linux-crisv32-low.cc (class crisv32_target) <get_regs_info>:
2642	Declare.
2643	(crisv32_regs_info): Turn into ...
2644	(crisv32_target::get_regs_info): ...this.
2645	(the_low_target): Remove the op field.
2646	* linux-ia64-low.cc (class ia64_target) <get_regs_info>: Declare.
2647	(ia64_regs_info): Turn into ...
2648	(ia64_target::get_regs_info): ...this.
2649	(the_low_target): Remove the op field.
2650	* linux-m32r-low.cc (class m32r_target) <get_regs_info>: Declare.
2651	(m32r_regs_info): Turn into ...
2652	(m32r_target::get_regs_info): ...this.
2653	(the_low_target): Remove the op field.
2654	* linux-m68k-low.cc (class m68k_target) <get_regs_info>: Declare.
2655	(m68k_regs_info): Turn into ...
2656	(m68k_target::get_regs_info): ...this.
2657	(the_low_target): Remove the op field.
2658	* linux-mips-low.cc (class mips_target) <get_regs_info>: Declare.
2659	(mips_regs_info): Turn into ...
2660	(mips_target::get_regs_info): ...this.
2661	(the_low_target): Remove the op field.
2662	(get_usrregs_info): Update the call to the op.
2663	* linux-nios2-low.cc (class nios2_target) <get_regs_info>: Declare.
2664	(nios2_regs_info): Turn into ...
2665	(nios2_target::get_regs_info): ...this.
2666	(the_low_target): Remove the op field.
2667	* linux-ppc-low.cc (class ppc_target) <get_regs_info>: Declare.
2668	(ppc_regs_info): Turn into ...
2669	(ppc_target::get_regs_info): ...this.
2670	(the_low_target): Remove the op field.
2671	* linux-riscv-low.cc (class riscv_target) <get_regs_info>: Declare.
2672	(riscv_regs_info): Turn into ...
2673	(riscv_target::get_regs_info): ...this.
2674	(the_low_target): Remove the op field.
2675	* linux-s390-low.cc (class s390_target) <get_regs_info>: Declare.
2676	(s390_regs_info): Turn into ...
2677	(s390_target::get_regs_info): ...this.
2678	(the_low_target): Remove the op field.
2679	(s390_collect_ptrace_register)
2680	(s390_supply_ptrace_register)
2681	(s390_fill_gregset): Update the call to the op.
2682	* linux-sh-low.cc (class sh_target) <get_regs_info>: Declare.
2683	(sh_regs_info): Turn into ...
2684	(sh_target::get_regs_info): ...this.
2685	(the_low_target): Remove the op field.
2686	* linux-sparc-low.cc (class sparc_target) <get_regs_info>: Declare.
2687	(sparc_regs_info): Turn into ...
2688	(sparc_target::get_regs_info): ...this.
2689	(the_low_target): Remove the op field.
2690	* linux-tic6x-low.cc (class tic6x_target) <get_regs_info>: Declare.
2691	(tic6x_regs_info): Turn into ...
2692	(tic6x_target::get_regs_info): ...this.
2693	(the_low_target): Remove the op field.
2694	* linux-tile-low.cc (class tile_target) <get_regs_info>: Declare.
2695	(tile_regs_info): Turn into ...
2696	(tile_target::get_regs_info): ...this.
2697	(the_low_target): Remove the op field.
2698	* linux-xtensa-low.cc (class xtensa_target) <get_regs_info>:
2699	Declare.
2700	(xtensa_regs_info): Turn into ...
2701	(xtensa_target::get_regs_info): ...this.
2702	(the_low_target): Remove the op field.
2703
27042020-04-02  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
2705
2706	Turn the 'arch_setup' linux target op into a method of
2707	linux_process_target.
2708
2709	* linux-low.h (struct linux_target_ops) <arch_setup>: Delete.
2710	(class linux_process_target) <arch_setup_thread>
2711	<low_arch_setup>: New declarations.
2712	* linux-low.cc (linux_arch_setup): Delete.
2713	(linux_arch_setup_thread): Turn into...
2714	(linux_process_target::arch_setup_thread): ... this.
2715
2716	Update the callers below.
2717
2718	(linux_process_target::handle_extended_wait)
2719	(linux_process_target::post_create_inferior)
2720	(linux_process_target::filter_event)
2721
2722	* linux-x86-low.cc (class x86_target) <low_arch_setup>: New
2723	declaration.
2724	(x86_linux_update_xmltarget): Turn into...
2725	(x86_target::update_xmltarget): ...this.
2726	(x86_linux_process_qsupported): Update the call to
2727	x86_linux_update_xmltarget.
2728	(x86_arch_setup): Turn into ...
2729	(x86_target::low_arch_setup): ...this.
2730	(the_low_target): Remove the op field.
2731	* linux-aarch64-low.cc (class aarch64_target) <low_arch_setup>: New
2732	declaration.
2733	(aarch64_arch_setup): Turn into ...
2734	(aarch64_target::low_arch_setup): ...this.
2735	(the_low_target): Remove the op field.
2736	* linux-arm-low.cc (class arm_target) <low_arch_setup>: New
2737	declaration.
2738	(arm_arch_setup): Turn into ...
2739	(arm_target::low_arch_setup): ...this.
2740	(the_low_target): Remove the op field.
2741	* linux-bfin-low.cc (class bfin_target) <low_arch_setup>: New
2742	declaration.
2743	(bfin_arch_setup): Turn into ...
2744	(bfin_target::low_arch_setup): ...this.
2745	(the_low_target): Remove the op field.
2746	* linux-cris-low.cc (class cris_target) <low_arch_setup>: New
2747	declaration.
2748	(cris_arch_setup): Turn into ...
2749	(cris_target::low_arch_setup): ...this.
2750	(the_low_target): Remove the op field.
2751	* linux-crisv32-low.cc (class crisv32_target) <low_arch_setup>: New
2752	declaration.
2753	(crisv32_arch_setup): Turn into ...
2754	(crisv32_target::low_arch_setup): ...this.
2755	(the_low_target): Remove the op field.
2756	* linux-ia64-low.cc (class ia64_target) <low_arch_setup>: New
2757	declaration.
2758	(ia64_arch_setup): Turn into ...
2759	(ia64_target::low_arch_setup): ...this.
2760	(the_low_target): Remove the op field.
2761	* linux-m32r-low.cc (class m32r_target) <low_arch_setup>: New
2762	declaration.
2763	(m32r_arch_setup): Turn into ...
2764	(m32r_target::low_arch_setup): ...this.
2765	(the_low_target): Remove the op field.
2766	* linux-m68k-low.cc (class m68k_target) <low_arch_setup>: New
2767	declaration.
2768	(m68k_arch_setup): Turn into ...
2769	(m68k_target::low_arch_setup): ...this.
2770	(the_low_target): Remove the op field.
2771	* linux-mips-low.cc (class mips_target) <low_arch_setup>: New
2772	declaration.
2773	(mips_arch_setup): Turn into ...
2774	(mips_target::low_arch_setup): ...this.
2775	(the_low_target): Remove the op field.
2776	* linux-nios2-low.cc (class nios2_target) <low_arch_setup>: New
2777	declaration.
2778	(nios2_arch_setup): Turn into ...
2779	(nios2_target::low_arch_setup): ...this.
2780	(the_low_target): Remove the op field.
2781	* linux-ppc-low.cc (class ppc_target) <low_arch_setup>: New
2782	declaration.
2783	(ppc_arch_setup): Turn into ...
2784	(ppc_target::low_arch_setup): ...this.
2785	(the_low_target): Remove the op field.
2786	* linux-riscv-low.cc (class riscv_target) <low_arch_setup>: New
2787	declaration.
2788	(riscv_arch_setup): Turn into ...
2789	(riscv_target::low_arch_setup): ...this.
2790	(the_low_target): Remove the op field.
2791	* linux-s390-low.cc (class s390_target) <low_arch_setup>: New
2792	declaration.
2793	(s390_arch_setup): Turn into ...
2794	(s390_target::low_arch_setup): ...this.
2795	(the_low_target): Remove the op field.
2796	* linux-sh-low.cc (class sh_target) <low_arch_setup>: New
2797	declaration.
2798	(sh_arch_setup): Turn into ...
2799	(sh_target::low_arch_setup): ...this.
2800	(the_low_target): Remove the op field.
2801	* linux-sparc-low.cc (class sparc_target) <low_arch_setup>: New
2802	declaration.
2803	(sparc_arch_setup): Turn into ...
2804	(sparc_target::low_arch_setup): ...this.
2805	(the_low_target): Remove the op field.
2806	* linux-tic6x-low.cc (class tic6x_target) <low_arch_setup>: New
2807	declaration.
2808	(tic6x_arch_setup): Turn into ...
2809	(tic6x_target::low_arch_setup): ...this.
2810	(the_low_target): Remove the op field.
2811	* linux-tile-low.cc (class tile_target) <low_arch_setup>: New
2812	declaration.
2813	(tile_arch_setup): Turn into ...
2814	(tile_target::low_arch_setup): ...this.
2815	(the_low_target): Remove the op field.
2816	* linux-xtensa-low.cc (class xtensa_target) <low_arch_setup>: New
2817	declaration.
2818	(xtensa_arch_setup): Turn into ...
2819	(xtensa_target::low_arch_setup): ...this.
2820	(the_low_target): Remove the op field.
2821
28222020-04-02  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
2823
2824	* linux-low.h (the_linux_target): New extern declaration.
2825	* linux-low.cc (initialize_low): Use 'the_linux_target' to set
2826	'the_target'.
2827	(the_linux_target): Remove.
2828	* linux-x86-low.cc (class x86_target): New class.
2829	(the_x86_target): New static object.
2830	(the_linux_target): Define as pointer to the_x86_target.
2831	* linux-aarch64-low.cc (class aarch64_target): New class.
2832	(the_aarch64_target): New static object.
2833	(the_linux_target): Define as pointer to the_aarch64_target.
2834	* linux-arm-low.cc (class arm_target): New class.
2835	(the_arm_target): New static object.
2836	(the_linux_target): Define as pointer to the_arm_target.
2837	* linux-bfin-low.cc (class bfin_target): New class.
2838	(the_bfin_target): New static object.
2839	(the_linux_target): Define as pointer to the_bfin_target.
2840	* linux-cris-low.cc (class cris_target): New class.
2841	(the_cris_target): New static object.
2842	(the_linux_target): Define as pointer to the_cris_target.
2843	* linux-crisv32-low.cc (class crisv32_target): New class.
2844	(the_crisv32_target): New static object.
2845	(the_linux_target): Define as pointer to the_crisv32_target.
2846	* linux-ia64-low.cc (class ia64_target): New class.
2847	(the_ia64_target): New static object.
2848	(the_linux_target): Define as pointer to the_ia64_target.
2849	* linux-m32r-low.cc (class m32r_target): New class.
2850	(the_m32r_target): New static object.
2851	(the_linux_target): Define as pointer to the_m32r_target.
2852	* linux-m68k-low.cc (class m68k_target): New class.
2853	(the_m68k_target): New static object.
2854	(the_linux_target): Define as pointer to the_m68k_target.
2855	* linux-mips-low.cc (class mips_target): New class.
2856	(the_mips_target): New static object.
2857	(the_linux_target): Define as pointer to the_mips_target.
2858	* linux-nios2-low.cc (class nios2_target): New class.
2859	(the_nios2_target): New static object.
2860	(the_linux_target): Define as pointer to the_nios2_target.
2861	* linux-ppc-low.cc (class ppc_target): New class.
2862	(the_ppc_target): New static object.
2863	(the_linux_target): Define as pointer to the_ppc_target.
2864	* linux-riscv-low.cc (class riscv_target): New class.
2865	(the_riscv_target): New static object.
2866	(the_linux_target): Define as pointer to the_riscv_target.
2867	* linux-s390-low.cc (class s390_target): New class.
2868	(the_s390_target): New static object.
2869	(the_linux_target): Define as pointer to the_s390_target.
2870	* linux-sh-low.cc (class sh_target): New class.
2871	(the_sh_target): New static object.
2872	(the_linux_target): Define as pointer to the_sh_target.
2873	* linux-sparc-low.cc (class sparc_target): New class.
2874	(the_sparc_target): New static object.
2875	(the_linux_target): Define as pointer to the_sparc_target.
2876	* linux-tic6x-low.cc (class tic6x_target): New class.
2877	(the_tic6x_target): New static object.
2878	(the_linux_target): Define as pointer to the_tic6x_target.
2879	* linux-tile-low.cc (class tile_target): New class.
2880	(the_tile_target): New static object.
2881	(the_linux_target): Define as pointer to the_tile_target.
2882	* linux-xtensa-low.cc (class xtensa_target): New class.
2883	(the_xtensa_target): New static object.
2884	(the_linux_target): Define as pointer to the_xtensa_target.
2885
28862020-04-02  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
2887
2888	Turn some static functions in linux-low.cc into private methods of
2889	linux_process_target.
2890
2891	* linux-low.cc (handle_extended_wait): Turn into ...
2892	(linux_process_target::handle_extended_wait): ...this.  Call
2893	'mourn' on 'this' object instead of 'the_target'.
2894	(maybe_move_out_of_jump_pad): Turn into...
2895	(linux_process_target::maybe_move_out_of_jump_pad): ...this.
2896	(linux_low_filter_event): Turn into...
2897	(linux_process_target::filter_event): ...this.
2898	(linux_wait_for_event_filtered): Turn into...
2899	(linux_process_target::wait_for_event_filtered): ...this.
2900	(linux_wait_for_event): Turn into...
2901	(linux_process_target::wait_for_event): ...this.
2902	(linux_wait_1): Turn into...
2903	(linux_process_target::wait_1): ...this.
2904	(wait_for_sigstop): Turn into...
2905	(linux_process_target::wait_for_sigstop): ...this.
2906	(move_out_of_jump_pad_callback): Turn into...
2907	(linux_process_target::move_out_of_jump_pad): ...this.
2908	(stop_all_lwps): Turn into...
2909	(linux_process_target::stop_all_lwps): ...this.
2910	(start_step_over): Turn into...
2911	(linux_process_target::start_step_over): ...this.
2912	(complete_ongoing_step_over): Turn into...
2913	(linux_process_target::complete_ongoing_step_over): ...this.
2914	(proceed_all_lwps): Turn into...
2915	(linux_process_target::proceed_all_lwps): ...this.
2916	(unstop_all_lwps): Turn into...
2917	(linux_process_target::unstop_all_lwps): ...this.
2918
2919	* linux-low.h (class linux_process_target)
2920	<handle_extended_wait>
2921	<maybe_move_out_of_jump_pad>
2922	filter_event>
2923	<wait_for_event_filtered>
2924	<wait_for_event>
2925	<wait_1>
2926	<wait_for_sigstop>
2927	<move_out_of_jump_pad>
2928	<stop_all_lwps>
2929	<start_step_over>
2930	<complete_ongoing_step_over>
2931	<proceed_all_lwps>
2932	<unstop_all_lwps>: Declare.
2933
2934	Update the callers below.
2935
2936	* linux-low.cc (linux_process_target::attach): Update.
2937	(linux_process_target::stabilize_threads): Ditto.
2938	(linux_process_target::wait): Ditto.
2939
29402020-04-02  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
2941
2942	* linux-low.h (struct linux_target_ops): Update the comment for
2943	'cannot_store_register' to return 0 or 1.
2944	* linux-ppc-low.cc (ppc_cannot_store_register): Return 1 instead
2945	of 2.
2946
29472020-03-20  Simon Marchi  <simon.marchi@efficios.com>
2948
2949	* config.in: Re-generate.
2950	* configure: Re-generate.
2951
29522020-03-17  Kamil Rytarowski  <n54@gmx.com>
2953
2954	* regcache.cc (find_register_by_number): Update.
2955	* tdesc.cc (init_target_desc): Likewise.
2956	* tdesc.h (target_desc::reg_defs): Likewise.
2957
29582020-03-12  Tom Tromey  <tom@tromey.com>
2959
2960	* configure: Rebuild.
2961	* configure.ac (GDBSERVER_DEPFILES): Remove srv_selftest_objs.
2962	(WIN32APILIBS): New subst.
2963	* Makefile.in (SFILES, OBS, TAGS, GDBREPLAY_OBS): Remove
2964	gdbsupport files.
2965	(gdbsupport/%.o): Remove target.
2966	(GDBSUPPORT_BUILDDIR, GDBSUPPORT): New variables.
2967	(gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Add GDBSUPPORT.
2968	(WIN32APILIBS): New variable.
2969	(gdbserver$(EXEEXT)): Add WIN32APILIBS.
2970	(gdbreplay$(EXEEXT)): Likewise.
2971
29722020-03-12  Tom Tromey  <tom@tromey.com>
2973
2974	* config.in, configure: Rebuild.
2975	* configure.ac: Call ZW_GNU_GETTEXT_SISTER_DIR.
2976	* acinclude.m4: Include gettext-sister.m4.
2977	* Makefile.in (top_builddir, INTL, INTL_DEPS, INTL_CFLAGS): New
2978	variables.
2979	(INCLUDE_CFLAGS): Add INTL_CFLAGS.
2980	(gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Use INTL_DEPS, INTL.
2981
29822020-03-12  Simon Marchi  <simon.marchi@efficios.com>
2983
2984	* acinclude.m4: Update path to selftest.m4.
2985
29862020-03-12  Simon Marchi  <simon.marchi@efficios.com>
2987
2988	* configure.ac: Don't source bfd/development.sh, move
2989	GDB_AC_COMMON higher.
2990	* configure: Re-generate.
2991
29922020-03-12  Simon Marchi  <simon.marchi@efficios.com>
2993
2994	* configure: Re-generate.
2995
29962020-03-11  Simon Marchi  <simon.marchi@efficios.com>
2997
2998	* configure: Re-generate.
2999
30002020-03-06  Andrew Burgess  <andrew.burgess@embecosm.com>
3001
3002	* .dir-locals.el: New file.
3003
30042020-03-05  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
3005
3006	* .gitattributes: New file.
3007
30082020-03-02  Andrew Burgess  <andrew.burgess@embecosm.com>
3009
3010	* remote-utils.cc (prepare_resume_reply): Add ability to convert T
3011	reply into an S reply.
3012	* server.cc (disable_packet_T): New global.
3013	(captured_main): Set new global when appropriate.
3014	* server.h (disable_packet_T): Declare.
3015
30162020-02-21  Tom Tromey  <tom@tromey.com>
3017
3018	* Makefile.in (mostlyclean): New target.
3019
30202020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
3021
3022	* target.h (struct process_stratum_target): Remove.
3023	(class process_target): Rename to ...
3024	(class process_stratum_target): ... this.
3025	* linux-low.h (class linux_process_target): Derive from
3026	'process_stratum_target'.
3027	* linux-low.cc (linux_target_ops): Remove.
3028	(initialize_low): Set the_target to the singleton instance of
3029	linux_process_target.
3030	* lynx-low.h (class lynx_process_target): Derive from
3031	'process_stratum_target'.
3032	* lynx-low.cc (lynx_target_ops): Remove.
3033	(initialize_low): Set the_target to the singleton instance of
3034	lynx_process_target.
3035	* nto-low.h (class nto_process_target): Derive from
3036	'process_stratum_target'.
3037	* nto-low.cc (nto_target_ops): Remove.
3038	(initialize_low): Set the_target to the singleton instance of
3039	nto_process_target.
3040	* win32-low.h (class win32_process_target): Derive from
3041	'process_stratum_target'.
3042	* win32-low.cc (win32_target_ops): Remove.
3043	(initialize_low): Set the_target to the singleton instance of
3044	win32_process_target.
3045
3046	Replace 'the_target->pt' with 'the_target' in the uses below.
3047
3048	* hostio.cc (hostio_error)
3049	(handle_setfs)
3050	(handle_open)
3051	(handle_unlink)
3052	(handle_readlink)
3053	* linux-aarch32-low.cc (arm_breakpoint_at)
3054	* linux-aarch64-low.cc (aarch64_breakpoint_at)
3055	* linux-arm-low.cc (arm_sigreturn_next_pc)
3056	(arm_get_hwcap)
3057	(arm_get_syscall_trapinfo)
3058	* linux-cris-low.cc (cris_breakpoint_at)
3059	* linux-crisv32-low.cc (cris_breakpoint_at)
3060	* linux-low.cc (handle_extended_wait)
3061	(linux_wait_1)
3062	(linux_read_memory)
3063	(linux_process_target::breakpoint_kind_from_pc)
3064	(linux_get_auxv)
3065	* linux-m32r-low.cc (m32r_breakpoint_at)
3066	* linux-mips-low.cc (mips_breakpoint_at)
3067	* linux-nios2-low.cc (nios2_breakpoint_at)
3068	* linux-ppc-low.cc (ppc_breakpoint_at)
3069	* linux-s390-low.cc (s390_get_hwcap)
3070	* linux-sh-low.cc (sh_breakpoint_at)
3071	* linux-sparc-low.cc (sparc_fill_gregset_to_stack)
3072	(sparc_store_gregset_from_stack)
3073	(sparc_breakpoint_at)
3074	* linux-tic6x-low.cc (tic6x_breakpoint_at)
3075	* linux-tile-low.cc (tile_breakpoint_at)
3076	* linux-x86-low.cc (x86_breakpoint_at)
3077	* linux-xtensa-low.cc (xtensa_breakpoint_at)
3078	* mem-break.cc (bp_size)
3079	(bp_opcode)
3080	(insert_memory_breakpoint)
3081	(set_raw_breakpoint_at)
3082	(delete_raw_breakpoint)
3083	(z_type_supported)
3084	(uninsert_raw_breakpoint)
3085	(reinsert_raw_breakpoint)
3086	(validate_inserted_breakpoint)
3087	* regcache.cc (regcache_read_pc)
3088	(regcache_write_pc)
3089	* remote-utils.cc (putpkt_binary_1)
3090	(input_interrupt)
3091	(getpkt)
3092	(prepare_resume_reply)
3093	* server.cc (handle_general_set)
3094	(handle_detach)
3095	(handle_qxfer_auxv)
3096	(handle_qxfer_exec_file)
3097	(handle_qxfer_libraries_svr4)
3098	(handle_qxfer_osdata)
3099	(handle_qxfer_siginfo)
3100	(handle_qxfer_fdpic)
3101	(handle_query)
3102	(resume)
3103	(handle_v_requests)
3104	(queue_stop_reply_callback)
3105	(captured_main)
3106	* target.cc (prepare_to_access_memory)
3107	(done_accessing_memory)
3108	(read_inferior_memory)
3109	(target_write_memory)
3110	(target_stop_and_wait)
3111	(target_wait)
3112	(target_mourn_inferior)
3113	(target_continue_no_signal)
3114	(target_continue)
3115	(target_supports_multi_process)
3116	(kill_inferior)
3117	* target.h
3118	(target_create_inferior)
3119	(target_post_create_inferior)
3120	(myattach)
3121	(target_supports_fork_events)
3122	(target_supports_vfork_events)
3123	(target_supports_exec_events)
3124	(target_handle_new_gdb_connection)
3125	(detach_inferior)
3126	(mythread_alive)
3127	(fetch_inferior_registers)
3128	(store_inferior_registers)
3129	(join_inferior)
3130	(target_supports_non_stop)
3131	(target_async)
3132	(target_process_qsupported)
3133	(target_supports_catch_syscall)
3134	(target_get_ipa_tdesc_idx)
3135	(target_supports_tracepoints)
3136	(target_supports_fast_tracepoints)
3137	(target_get_min_fast_tracepoint_insn_len)
3138	(target_thread_stopped)
3139	(target_pause_all)
3140	(target_unpause_all)
3141	(target_stabilize_threads)
3142	(target_install_fast_tracepoint_jump_pad)
3143	(target_emit_ops)
3144	(target_supports_disable_randomization)
3145	(target_supports_agent)
3146	(target_enable_btrace)
3147	(target_disable_btrace)
3148	(target_read_btrace)
3149	(target_read_btrace_conf)
3150	(target_supports_range_stepping)
3151	(target_supports_stopped_by_sw_breakpoint)
3152	(target_stopped_by_sw_breakpoint)
3153	(target_supports_stopped_by_hw_breakpoint)
3154	(target_supports_hardware_single_step)
3155	(target_stopped_by_hw_breakpoint)
3156	(target_breakpoint_kind_from_pc)
3157	(target_breakpoint_kind_from_current_state)
3158	(target_supports_software_single_step)
3159	(target_core_of_thread)
3160	(target_thread_name)
3161	(target_thread_handle)
3162	* win32-low.cc (do_initial_child_stuff)
3163
3164	Rename target op default definitions listed below.
3165
3166	* target.cc (process_target::post_create_inferior): Rename as ...
3167	(process_stratum_target::post_create_inferior): ... this.
3168	(process_target::prepare_to_access_memory): Rename as ...
3169	(process_stratum_target::prepare_to_access_memory): ... this.
3170	(process_target::done_accessing_memory): Rename as ...
3171	(process_stratum_target::done_accessing_memory): ... this.
3172	(process_target::look_up_symbols): Rename as ...
3173	(process_stratum_target::look_up_symbols): ... this.
3174	(process_target::supports_read_auxv): Rename as ...
3175	(process_stratum_target::supports_read_auxv): ... this.
3176	(process_target::read_auxv): Rename as ...
3177	(process_stratum_target::read_auxv): ... this.
3178	(process_target::supports_z_point_type): Rename as ...
3179	(process_stratum_target::supports_z_point_type): ... this.
3180	(process_target::insert_point): Rename as ...
3181	(process_stratum_target::insert_point): ... this.
3182	(process_target::remove_point): Rename as ...
3183	(process_stratum_target::remove_point): ... this.
3184	(process_target::stopped_by_sw_breakpoint): Rename as ...
3185	(process_stratum_target::stopped_by_sw_breakpoint): ... this.
3186	(process_target::supports_stopped_by_sw_breakpoint): Rename as ...
3187	(process_stratum_target::supports_stopped_by_sw_breakpoint): ... this.
3188	(process_target::stopped_by_hw_breakpoint): Rename as ...
3189	(process_stratum_target::stopped_by_hw_breakpoint): ... this.
3190	(process_target::supports_stopped_by_hw_breakpoint): Rename as ...
3191	(process_stratum_target::supports_stopped_by_hw_breakpoint): ... this.
3192	(process_target::supports_hardware_single_step): Rename as ...
3193	(process_stratum_target::supports_hardware_single_step): ... this.
3194	(process_target::stopped_by_watchpoint): Rename as ...
3195	(process_stratum_target::stopped_by_watchpoint): ... this.
3196	(process_target::stopped_data_address): Rename as ...
3197	(process_stratum_target::stopped_data_address): ... this.
3198	(process_target::supports_read_offsets): Rename as ...
3199	(process_stratum_target::supports_read_offsets): ... this.
3200	(process_target::read_offsets): Rename as ...
3201	(process_stratum_target::read_offsets): ... this.
3202	(process_target::supports_get_tls_address): Rename as ...
3203	(process_stratum_target::supports_get_tls_address): ... this.
3204	(process_target::get_tls_address): Rename as ...
3205	(process_stratum_target::get_tls_address): ... this.
3206	(process_target::hostio_last_error): Rename as ...
3207	(process_stratum_target::hostio_last_error): ... this.
3208	(process_target::supports_qxfer_osdata): Rename as ...
3209	(process_stratum_target::supports_qxfer_osdata): ... this.
3210	(process_target::qxfer_osdata): Rename as ...
3211	(process_stratum_target::qxfer_osdata): ... this.
3212	(process_target::supports_qxfer_siginfo): Rename as ...
3213	(process_stratum_target::supports_qxfer_siginfo): ... this.
3214	(process_target::qxfer_siginfo): Rename as ...
3215	(process_stratum_target::qxfer_siginfo): ... this.
3216	(process_target::supports_non_stop): Rename as ...
3217	(process_stratum_target::supports_non_stop): ... this.
3218	(process_target::async): Rename as ...
3219	(process_stratum_target::async): ... this.
3220	(process_target::start_non_stop): Rename as ...
3221	(process_stratum_target::start_non_stop): ... this.
3222	(process_target::supports_multi_process): Rename as ...
3223	(process_stratum_target::supports_multi_process): ... this.
3224	(process_target::supports_fork_events): Rename as ...
3225	(process_stratum_target::supports_fork_events): ... this.
3226	(process_target::supports_vfork_events): Rename as ...
3227	(process_stratum_target::supports_vfork_events): ... this.
3228	(process_target::supports_exec_events): Rename as ...
3229	(process_stratum_target::supports_exec_events): ... this.
3230	(process_target::handle_new_gdb_connection): Rename as ...
3231	(process_stratum_target::handle_new_gdb_connection): ... this.
3232	(process_target::handle_monitor_command): Rename as ...
3233	(process_stratum_target::handle_monitor_command): ... this.
3234	(process_target::core_of_thread): Rename as ...
3235	(process_stratum_target::core_of_thread): ... this.
3236	(process_target::supports_read_loadmap): Rename as ...
3237	(process_stratum_target::supports_read_loadmap): ... this.
3238	(process_target::read_loadmap): Rename as ...
3239	(process_stratum_target::read_loadmap): ... this.
3240	(process_target::process_qsupported): Rename as ...
3241	(process_stratum_target::process_qsupported): ... this.
3242	(process_target::supports_tracepoints): Rename as ...
3243	(process_stratum_target::supports_tracepoints): ... this.
3244	(process_target::read_pc): Rename as ...
3245	(process_stratum_target::read_pc): ... this.
3246	(process_target::write_pc): Rename as ...
3247	(process_stratum_target::write_pc): ... this.
3248	(process_target::supports_thread_stopped): Rename as ...
3249	(process_stratum_target::supports_thread_stopped): ... this.
3250	(process_target::thread_stopped): Rename as ...
3251	(process_stratum_target::thread_stopped): ... this.
3252	(process_target::supports_get_tib_address): Rename as ...
3253	(process_stratum_target::supports_get_tib_address): ... this.
3254	(process_target::get_tib_address): Rename as ...
3255	(process_stratum_target::get_tib_address): ... this.
3256	(process_target::pause_all): Rename as ...
3257	(process_stratum_target::pause_all): ... this.
3258	(process_target::unpause_all): Rename as ...
3259	(process_stratum_target::unpause_all): ... this.
3260	(process_target::stabilize_threads): Rename as ...
3261	(process_stratum_target::stabilize_threads): ... this.
3262	(process_target::supports_fast_tracepoints): Rename as ...
3263	(process_stratum_target::supports_fast_tracepoints): ... this.
3264	(process_target::get_min_fast_tracepoint_insn_len): Rename as ...
3265	(process_stratum_target::get_min_fast_tracepoint_insn_len): ... this.
3266	(process_target::emit_ops): Rename as ...
3267	(process_stratum_target::emit_ops): ... this.
3268	(process_target::supports_disable_randomization): Rename as ...
3269	(process_stratum_target::supports_disable_randomization): ... this.
3270	(process_target::supports_qxfer_libraries_svr4): Rename as ...
3271	(process_stratum_target::supports_qxfer_libraries_svr4): ... this.
3272	(process_target::qxfer_libraries_svr4): Rename as ...
3273	(process_stratum_target::qxfer_libraries_svr4): ... this.
3274	(process_target::supports_agent): Rename as ...
3275	(process_stratum_target::supports_agent): ... this.
3276	(process_target::enable_btrace): Rename as ...
3277	(process_stratum_target::enable_btrace): ... this.
3278	(process_target::disable_btrace): Rename as ...
3279	(process_stratum_target::disable_btrace): ... this.
3280	(process_target::read_btrace): Rename as ...
3281	(process_stratum_target::read_btrace): ... this.
3282	(process_target::read_btrace_conf): Rename as ...
3283	(process_stratum_target::read_btrace_conf): ... this.
3284	(process_target::supports_range_stepping): Rename as ...
3285	(process_stratum_target::supports_range_stepping): ... this.
3286	(process_target::supports_pid_to_exec_file): Rename as ...
3287	(process_stratum_target::supports_pid_to_exec_file): ... this.
3288	(process_target::pid_to_exec_file): Rename as ...
3289	(process_stratum_target::pid_to_exec_file): ... this.
3290	(process_target::supports_multifs): Rename as ...
3291	(process_stratum_target::supports_multifs): ... this.
3292	(process_target::multifs_open): Rename as ...
3293	(process_stratum_target::multifs_open): ... this.
3294	(process_target::multifs_unlink): Rename as ...
3295	(process_stratum_target::multifs_unlink): ... this.
3296	(process_target::multifs_readlink): Rename as ...
3297	(process_stratum_target::multifs_readlink): ... this.
3298	(process_target::breakpoint_kind_from_pc): Rename as ...
3299	(process_stratum_target::breakpoint_kind_from_pc): ... this.
3300	(process_target::breakpoint_kind_from_current_state): Rename as ...
3301	(process_stratum_target::breakpoint_kind_from_current_state): ... this.
3302	(process_target::thread_name): Rename as ...
3303	(process_stratum_target::thread_name): ... this.
3304	(process_target::thread_handle): Rename as ...
3305	(process_stratum_target::thread_handle): ... this.
3306	(process_target::supports_software_single_step): Rename as ...
3307	(process_stratum_target::supports_software_single_step): ... this.
3308	(process_target::supports_catch_syscall): Rename as ...
3309	(process_stratum_target::supports_catch_syscall): ... this.
3310	(process_target::get_ipa_tdesc_idx): Rename as ...
3311	(process_stratum_target::get_ipa_tdesc_idx): ... this.
3312
33132020-02-20  Pedro Alves  <palves@redhat.com>
3314
3315	* target.cc (set_target_ops): Simply copy the given target pointer
3316	instead of creating a copy of the pointed object.
3317
33182020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
3319
3320	Turn process_stratum_target's get_ipa_tdesc_idx op into a method
3321	of process_target.
3322
3323	* target.h (struct process_stratum_target): Remove the target op.
3324	(class process_target): Add the target op.
3325	(target_get_ipa_tdesc_idx): Update the macro.
3326	* target.cc (process_target::get_ipa_tdesc_idx): Define.
3327
3328	Update the derived classes and callers below.
3329
3330	* linux-low.cc (linux_target_ops): Update.
3331	(linux_get_ipa_tdesc_idx): Turn into ...
3332	(linux_process_target::get_ipa_tdesc_idx): ... this.
3333	* linux-low.h (class linux_process_target): Update.
3334	* lynx-low.cc (lynx_target_ops): Update.
3335	* nto-low.cc (nto_target_ops): Update.
3336	* win32-low.cc (win32_target_ops): Update.
3337
33382020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
3339
3340	Turn process_stratum_target's supports_catch_syscall op into a
3341	method of process_target.
3342
3343	* target.h (struct process_stratum_target): Remove the target op.
3344	(class process_target): Add the target op.
3345	(target_supports_catch_syscall): Update the macro.
3346	* target.cc (process_target::supports_catch_syscall): Define.
3347
3348	Update the derived classes and callers below.
3349
3350	* linux-low.cc (linux_target_ops): Update.
3351	(linux_supports_catch_syscall): Turn into ...
3352	(linux_process_target::supports_catch_syscall): ... this.
3353	* linux-low.h (class linux_process_target): Update.
3354	* lynx-low.cc (lynx_target_ops): Update.
3355	* nto-low.cc (nto_target_ops): Update.
3356	* win32-low.cc (win32_target_ops): Update.
3357
33582020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
3359
3360	Turn process_stratum_target's supports_software_single_step op
3361	into a method of process_target.
3362
3363	* target.h (struct process_stratum_target): Remove the target op.
3364	(class process_target): Add the target op.
3365	(target_supports_software_single_step): Update the macro.
3366	* target.cc (process_target::supports_software_single_step): Define.
3367
3368	Update the derived classes and callers below.
3369
3370	* linux-low.cc (linux_target_ops): Update.
3371	(linux_supports_software_single_step): Turn into ...
3372	(linux_process_target::supports_software_single_step): ... this.
3373	* linux-low.h (class linux_process_target): Update.
3374	* lynx-low.cc (lynx_target_ops): Update.
3375	* nto-low.cc (nto_target_ops): Update.
3376	* win32-low.cc (win32_target_ops): Update.
3377
33782020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
3379
3380	Turn process_stratum_target's thread_name and thread_handle ops
3381	into methods of process_target.
3382
3383	* target.h (struct process_stratum_target): Remove the target ops.
3384	(class process_target): Add the target ops.
3385	(target_thread_name): Update the macro.
3386	(target_thread_handle): Update the macro.
3387	* target.cc (process_target::thread_name): Define.
3388	(process_target::thread_handle): Define.
3389
3390	Update the derived classes and callers below.
3391
3392	* linux-low.cc (linux_target_ops): Update.
3393	(linux_process_target::thread_name): Define.
3394	(linux_process_target::thread_handle): Define.
3395	* linux-low.h (class linux_process_target): Update.
3396	* lynx-low.cc (lynx_target_ops): Update.
3397	* nto-low.cc (nto_target_ops): Update.
3398	* win32-low.cc (win32_target_ops): Update.
3399
34002020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
3401
3402	Turn process_stratum_target's breakpoint_kind_from_pc,
3403	sw_breakpoint_from_kind, and breakpoint_kind_from_current_state
3404	ops into methods of process_target.
3405
3406	* target.h (struct process_stratum_target): Remove the target op.
3407	(class process_target): Add the target op.
3408	(target_breakpoint_kind_from_pc): Update the macro.
3409	(target_breakpoint_kind_from_current_state): Update the macro.
3410	(default_breakpoint_kind_from_pc): Remove declaration.
3411	* target.cc (default_breakpoint_kind_from_pc): Turn into ...
3412	(process_target::breakpoint_kind_from_pc): ... this.
3413	(process_target::breakpoint_kind_from_current_state): Define.
3414
3415	Update the derived classes and callers below.
3416
3417	* mem-break.cc (bp_size): Update.
3418	(bp_opcode): Update.
3419	* linux-low.cc (linux_target_ops): Update.
3420	(linux_wait_1): Update.
3421	(linux_breakpoint_kind_from_pc): Turn into ...
3422	(linux_process_target::breakpoint_kind_from_pc): ... this.
3423	(linux_sw_breakpoint_from_kind): Turn into ...
3424	(linux_process_target::sw_breakpoint_from_kind): ... this.
3425	(linux_breakpoint_kind_from_current_state): Turn into ...
3426	(linux_process_target::breakpoint_kind_from_current_state): ... this.
3427	* linux-low.h (class linux_process_target): Update.
3428	* lynx-low.cc (lynx_target_ops): Update.
3429	(lynx_process_target::sw_breakpoint_from_kind): Define.
3430	* lynx-low.h (class lynx_process_target): Update.
3431	* nto-low.cc (nto_target_ops): Update.
3432	(nto_sw_breakpoint_from_kind): Turn into ...
3433	(nto_process_target::sw_breakpoint_from_kind): ... this.
3434	* nto-low.h (class nto_process_target): Update.
3435	* win32-low.cc (win32_target_ops): Update.
3436	(win32_sw_breakpoint_from_kind): Turn into ...
3437	(win32_process_target::sw_breakpoint_from_kind): ... this.
3438	* win32-low.h (class win32_process_target): Update.
3439
34402020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
3441
3442	Turn process_stratum_target's multifs_open, multifs_readlink,
3443	multifs_unlink ops into methods of process_target.
3444
3445	* target.h (struct process_stratum_target): Remove the target ops.
3446	(class process_target): Add the target ops.  Also add
3447	'supports_multifs'.
3448	* target.cc: Include "fcntl.h", "unistd.h", "sys/types.h", and
3449	"sys/stat.h".
3450	(process_target::supports_multifs): Define.
3451	(process_target::multifs_open): Define.
3452	(process_target::multifs_readlink): Define.
3453	(process_target::multifs_unlink): Define.
3454
3455	Update the derived classes and callers below.
3456
3457	* hostio.cc (handle_setfs): Update.
3458	(handle_open): Update.
3459	(handle_unlink): Update.
3460	(handle_readlink): Update.
3461	* linux-low.cc (linux_target_ops): Update.
3462	(linux_process_target::supports_multifs): Define.
3463	(linux_process_target::multifs_open): Define.
3464	(linux_process_target::multifs_readlink): Define.
3465	(linux_process_target::multifs_unlink): Define.
3466	* linux-low.h (class linux_process_target): Update.
3467	* lynx-low.cc (lynx_target_ops): Update.
3468	* nto-low.cc (nto_target_ops): Update.
3469	* win32-low.cc (win32_target_ops): Update.
3470
34712020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
3472
3473	Turn process_stratum_target's pid_to_exec_file op into a method
3474	of process_target.
3475
3476	* target.h (struct process_stratum_target): Remove the target op.
3477	(class process_target): Add the target op.  Also add
3478	'supports_pid_to_exec_file'.
3479	* target.cc (process_target::pid_to_exec_file): Define.
3480	(process_target::supports_pid_to_exec_file): Define.
3481
3482	Update the derived classes and callers below.
3483
3484	* server.cc (handle_qxfer_exec_file): Update.
3485	(handle_query): Update.
3486	* linux-low.cc (linux_target_ops): Update.
3487	(linux_process_target::supports_pid_to_exec_file): Define.
3488	(linux_process_target::pid_to_exec_file): Define.
3489	* linux-low.h (class linux_process_target): Update.
3490	* lynx-low.cc (lynx_target_ops): Update.
3491	* nto-low.cc (nto_target_ops): Update.
3492	* win32-low.cc (win32_target_ops): Update.
3493
34942020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
3495
3496	Turn process_stratum_target's supports_range_stepping op into a
3497	method of process_target.
3498
3499	* target.h (struct process_stratum_target): Remove the target op.
3500	(class process_target): Add the target op.
3501	(target_supports_range_stepping): Update the macro.
3502	* target.cc (process_target::supports_range_stepping): Define.
3503
3504	Update the derived classes and callers below.
3505
3506	* linux-low.cc (linux_target_ops): Update.
3507	(linux_supports_range_stepping): Turn into ...
3508	(linux_process_target::supports_range_stepping): ... this.
3509	* linux-low.h (class linux_process_target): Update.
3510	* lynx-low.cc (lynx_target_ops): Update.
3511	* nto-low.cc (nto_target_ops): Update.
3512	* win32-low.cc (win32_target_ops): Update.
3513
35142020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
3515
3516	Turn process_stratum_target's btrace-related ops (enable_btrace,
3517	disable_btrace, read_btrace, read_btrace_conf) into methods of
3518	process_target.
3519
3520	* target.h (struct process_stratum_target): Remove the target ops.
3521	(class process_target): Add the target ops.
3522	(target_enable_btrace): Update.
3523	(target_disable_btrace): Update.
3524	(target_read_btrace): Update.
3525	(target_read_btrace_conf): Update.
3526	* target.cc (process_target::enable_btrace): Define.
3527	(process_target::disable_btrace): Define.
3528	(process_target::read_btrace): Define.
3529	(process_target::read_btrace_conf): Define.
3530
3531	Update the derived classes and callers below.
3532
3533	* linux-low.cc (linux_target_ops): Update.
3534	(linux_process_target:enable_btrace): Define as a wrapper around
3535	linux_enable_btrace.
3536	(linux_low_disable_btrace): Turn into ...
3537	(linux_process_target::disable_btrace): ... this.
3538	(linux_low_read_btrace): Turn into ...
3539	(linux_process_target::read_btrace): ... this.
3540	(linux_low_btrace_conf): Turn into ...
3541	(linux_process_target::read_btrace_conf): ... this.
3542	* linux-low.h (class linux_process_target): Update.
3543	* lynx-low.cc (lynx_target_ops): Update.
3544	* nto-low.cc (nto_target_ops): Update.
3545	* win32-low.cc (win32_target_ops): Update.
3546
35472020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
3548
3549	Turn process_stratum_target's supports_agent op into a method of
3550	process_target.
3551
3552	* target.h (struct process_stratum_target): Remove the target op.
3553	(class process_target): Add the target op.
3554	(target_supports_agent): Update the macro.
3555	* target.cc (process_target::supports_agent): Define.
3556
3557	Update the derived classes and callers below.
3558
3559	* linux-low.cc (linux_target_ops): Update.
3560	(linux_supports_agent): Turn into ...
3561	(linux_process_target::supports_agent): ... this.
3562	* linux-low.h (class linux_process_target): Update.
3563	* lynx-low.cc (lynx_target_ops): Update.
3564	* nto-low.cc (nto_target_ops): Update.
3565	* win32-low.cc (win32_target_ops): Update.
3566
35672020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
3568
3569	Turn process_stratum_target's qxfer_libraries_svr4 op into a
3570	method of process_target.
3571
3572	* target.h (struct process_stratum_target): Remove the target op.
3573	(class process_target): Add the target op.  Also add
3574	'supports_qxfer_libraries_svr4'.
3575	* target.cc (process_target::qxfer_libraries_svr4): Define.
3576	(process_target::supports_qxfer_libraries_svr4): Define.
3577
3578	Update the derived classes and callers below.
3579
3580	* server.cc (handle_qxfer_libraries_svr4): Update.
3581	(handle_query): Update.
3582	* linux-low.cc (linux_target_ops): Update.
3583	(linux_process_target::supports_qxfer_libraries_svr4): Define.
3584	(linux_qxfer_libraries_svr4): Turn into ...
3585	(linux_process_target::qxfer_libraries_svr4): ... this.
3586	* linux-low.h (class linux_process_target): Update.
3587	* lynx-low.cc (lynx_target_ops): Update.
3588	* nto-low.cc (nto_target_ops): Update.
3589	* win32-low.cc (win32_target_ops): Update.
3590
35912020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
3592
3593	Turn process_stratum_target's supports_disable_randomization op
3594	into a method of process_target.
3595
3596	* target.h (struct process_stratum_target): Remove the target op.
3597	(class process_target): Add the target op.
3598	(target_supports_disable_randomization): Update the macro.
3599	* target.cc (process_target::supports_disable_randomization): Define.
3600
3601	Update the derived classes and callers below.
3602
3603	* linux-low.cc (linux_target_ops): Update.
3604	(linux_supports_disable_randomization): Turn into ...
3605	(linux_process_target::supports_disable_randomization): ... this.
3606	* linux-low.h (class linux_process_target): Update.
3607	* lynx-low.cc (lynx_target_ops): Update.
3608	* nto-low.cc (nto_target_ops): Update.
3609	* win32-low.cc (win32_target_ops): Update.
3610
36112020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
3612
3613	Turn process_stratum_target's emit_ops op into a method of
3614	process_target.
3615
3616	* target.h (struct process_stratum_target): Remove the target op.
3617	(class process_target): Add the target op.
3618	(target_emit_ops): Update the macro.
3619	* target.cc (process_target::emit_ops): Define.
3620
3621	Update the derived classes and callers below.
3622
3623	* linux-low.cc (linux_target_ops): Update.
3624	(linux_emit_ops): Turn into ...
3625	(linux_process_target::emit_ops): ... this.
3626	* linux-low.h (class linux_process_target): Update.
3627	* lynx-low.cc (lynx_target_ops): Update.
3628	* nto-low.cc (nto_target_ops): Update.
3629	* win32-low.cc (win32_target_ops): Update.
3630
36312020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
3632
3633	Turn process_stratum_target's install_fast_tracepoint_jump_pad
3634	and get_min_fast_tracepoint_insn_len ops into methods of
3635	process_target.
3636
3637	* target.h (struct process_stratum_target): Remove the target ops.
3638	(class process_target): Add the target ops.  Also add
3639	'supports_fast_tracepoints'.
3640	(target_supports_fast_tracepoints): Update the macro.
3641	(target_get_min_fast_tracepoint_insn_len): Update the macro.
3642	(install_fast_tracepoint_jump_pad): Update and rename the macro
3643	to ...
3644	(target_install_fast_tracepoint_jump_pad): ... this.
3645	* target.cc (process_target::supports_fast_tracepoints): Define.
3646	(process_target::install_fast_tracepoint_jump_pad): Define.
3647	(process_target::get_min_fast_tracepoint_insn_len): Define.
3648
3649	Update the derived classes and callers below.
3650
3651	* tracepoint.cc (install_fast_tracepoint): Update.
3652	* linux-low.cc (linux_target_ops): Update.
3653	(linux_process_target::supports_fast_tracepoints): Define.
3654	(linux_install_fast_tracepoint_jump_pad): Turn into ...
3655	(linux_process_target::install_fast_tracepoint_jump_pad): ... this.
3656	(linux_get_min_fast_tracepoint_insn_len): Turn into ...
3657	(linux_process_target::get_min_fast_tracepoint_insn_len): ... this.
3658	* linux-low.h (class linux_process_target): Update.
3659	* lynx-low.cc (lynx_target_ops): Update.
3660	* nto-low.cc (nto_target_ops): Update.
3661	* win32-low.cc (win32_target_ops): Update.
3662
36632020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
3664
3665	Turn process_stratum_target's stabilize_threads op into a
3666	method of process_target.
3667
3668	* target.h (struct process_stratum_target): Remove the target op.
3669	(class process_target): Add the target op.
3670	(target_stabilize_threads): Update the macro.
3671	* target.cc (process_target::stabilize_threads): Define.
3672
3673	Update the derived classes and callers below.
3674
3675	* server.cc (handle_status): Update.
3676	* tracepoint.cc (cmd_qtdp): Update.
3677	(cmd_qtstart): Update.
3678	* linux-low.cc (linux_target_ops): Update.
3679	(linux_stabilize_threads): Turn into ...
3680	(linux_process_target::stabilize_threads): ... this.
3681	(linux_wait_1): Update.
3682	* linux-low.h (class linux_process_target): Update.
3683	* lynx-low.cc (lynx_target_ops): Update.
3684	* nto-low.cc (nto_target_ops): Update.
3685	* win32-low.cc (win32_target_ops): Update.
3686
36872020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
3688
3689	Turn process_stratum_target's pause_all and unpause_all ops
3690	into methods of process_target.
3691
3692	* target.h (struct process_stratum_target): Remove the target ops.
3693	(class process_target): Add the target ops.
3694	(pause_all): Update the macro and rename to...
3695	(target_pause_all): ... this.
3696	(unpause_all): Update the macro and rename to...
3697	(target_unpause_all): ... this.
3698	* target.cc (process_target::pause_all): Define.
3699	(process_target::unpause_all): Define.
3700
3701	Update the derived classes and callers below.
3702
3703	* server.cc (handle_status): Update.
3704	* tracepoint.cc (clear_installed_tracepoints): Update.
3705	(cmd_qtdp): Update.
3706	(cmd_qtstart): Update.
3707	(stop_tracing): Update.
3708	(cmd_qtstatus): Update.
3709	(upload_fast_traceframes): Update.
3710	(run_inferior_command): Update.
3711	* linux-low.cc (linux_target_ops): Update.
3712	(linux_pause_all): Turn into ...
3713	(linux_process_target::pause_all): ... this.
3714	(linux_unpause_all): Turn into ...
3715	(linux_process_target::unpause_all): ... this.
3716	(linux_process_target::prepare_to_access_memory): Update.
3717	(linux_process_target::done_accessing_memory): Update.
3718	* linux-low.h (class linux_process_target): Update.
3719	* lynx-low.cc (lynx_target_ops): Update.
3720	* nto-low.cc (nto_target_ops): Update.
3721	* win32-low.cc (win32_target_ops): Update.
3722
37232020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
3724
3725	Turn process_stratum_target's get_tib_address op into a method of
3726	process_target.
3727
3728	* target.h (struct process_stratum_target): Remove the target op.
3729	(class process_target): Add the target op.  Also add
3730	'supports_get_tib_address'.
3731	* target.cc (process_target::get_tib_address): Define.
3732	(process_target::supports_get_tib_address): Define.
3733
3734	Update the derived classes and callers below.
3735
3736	* server.cc (handle_query): Update.
3737	* linux-low.cc (win32_target_ops): Update.
3738	* lynx-low.cc (lynx_target_ops): Update.
3739	* nto-low.cc (nto_target_ops): Update.
3740	* win32-low.cc (win32_target_ops): Update.
3741	(win32_process_target::supports_get_tib_address): Define.
3742	(win32_get_tib_address): Turn into ...
3743	(win32_process_target::get_tib_address): ... this.
3744	* win32-low.h (class win32_process_target): Update.
3745
37462020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
3747
3748	Turn process_stratum_target's thread_stopped op into a method of
3749	process_target.
3750
3751	* target.h (struct process_stratum_target): Remove the target op.
3752	(class process_target): Add the target op.  Also add
3753	'supports_thread_stopped'.
3754	(target_thread_stopped): Update the macro.
3755	* target.cc (process_target::thread_stopped): Define.
3756	(process_target::supports_thread_stopped): Define.
3757	(prepare_to_access_memory): Update.
3758
3759	Update the derived classes and callers below.
3760
3761	* server.cc (queue_stop_reply_callback): Update.
3762	* linux-low.cc (linux_target_ops): Update.
3763	(linux_process_target::supports_thread_stopped): Define.
3764	(linux_thread_stopped): Turn into ...
3765	(linux_process_target::thread_stopped): ... this.
3766	* linux-low.h (class linux_process_target): Update.
3767	* lynx-low.cc (lynx_target_ops): Update.
3768	* nto-low.cc (nto_target_ops): Update.
3769	* win32-low.cc (win32_target_ops): Update.
3770
37712020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
3772
3773	Turn process_stratum_target's read_pc and write_pc ops into
3774	methods of process_target.
3775
3776	* target.h (struct process_stratum_target): Remove the target ops.
3777	(class process_target): Add the target ops.
3778	* target.cc (process_target::read_pc): Define.
3779	(process_target::write_pc): Define.
3780
3781	Update the derived classes and callers below.
3782
3783	* regcache.cc (regcache_read_pc): Update.
3784	(regcache_write_pc): Update.
3785	* linux-low.cc (linux_target_ops): Update.
3786	(linux_read_pc): Turn into ...
3787	(linux_process_target::read_pc): ... this.
3788	(linux_write_pc): Turn into ...
3789	(linux_process_target::write_pc): ... this.
3790	* linux-low.h (class linux_process_target): Update.
3791	* lynx-low.cc (lynx_target_ops): Update.
3792	* nto-low.cc (nto_target_ops): Update.
3793	* win32-low.cc (win32_target_ops): Update.
3794
37952020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
3796
3797	Turn process_stratum_target's supports_tracepoints op into a
3798	method of process_target.
3799
3800	* target.h (struct process_stratum_target): Remove the target op.
3801	(class process_target): Add the target op.
3802	(target_supports_tracepoints): Update the macro.
3803	* target.cc (process_target::supports_tracepoints): Define.
3804
3805	Update the derived classes and callers below.
3806
3807	* linux-low.cc (linux_target_ops): Update.
3808	(linux_supports_tracepoints): Turn into ...
3809	(linux_process_target::supports_tracepoints): ... this.
3810	* linux-low.h (class linux_process_target): Update.
3811	* lynx-low.cc (lynx_target_ops): Update.
3812	* nto-low.cc (nto_target_ops): Update.
3813	* win32-low.cc (win32_target_ops): Update.
3814
38152020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
3816
3817	Turn process_stratum_target's process_qsupported op into a method
3818	of process_target.
3819
3820	* target.h (struct process_stratum_target): Remove the target op.
3821	(class process_target): Add the target op.
3822	(target_process_qsupported): Update the macro.
3823	* target.cc (process_target::process_qsupported): Define.
3824
3825	Update the derived classes and callers below.
3826
3827	* linux-low.cc (linux_target_ops): Update.
3828	(linux_process_qsupported): Turn into ...
3829	(linux_process_target::process_qsupported): ... this.
3830	* linux-low.h (class linux_process_target): Update.
3831	* lynx-low.cc (lynx_target_ops): Update.
3832	* nto-low.cc (nto_target_ops): Update.
3833	* win32-low.cc (win32_target_ops): Update.
3834
38352020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
3836
3837	Turn process_stratum_target's read_loadmap op into a method of
3838	process_target.
3839
3840	* target.h (struct process_stratum_target): Remove the target op.
3841	(class process_target): Add the target op.  Also add
3842	'supports_read_loadmap'.
3843	* target.cc (process_target::read_loadmap): Define.
3844	(process_target::supports_read_loadmap): Define.
3845
3846	Update the derived classes and callers below.
3847
3848	* server.cc (handle_qxfer_fdpic): Update.
3849	(handle_query): Update.
3850	* linux-low.cc (linux_target_ops): Update.
3851	(linux_process_target::supports_read_loadmap): Define.
3852	(linux_read_loadmap): Turn into ...
3853	(linux_process_target::read_loadmap): ... this.
3854	* linux-low.h (class linux_process_target): Update.
3855	* lynx-low.cc (lynx_target_ops): Update.
3856	* nto-low.cc (nto_target_ops): Update.
3857	* win32-low.cc (win32_target_ops): Update.
3858
38592020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
3860
3861	Turn process_stratum_target's core_of_thread op into a method of
3862	process_target.
3863
3864	* target.h (struct process_stratum_target): Remove the target op.
3865	(class process_target): Add the target op.
3866	(target_core_of_thread): Update the macro.
3867	* target.cc (process_target::core_of_thread): Define.
3868
3869	Update the derived classes and callers below.
3870
3871	* linux-low.cc (linux_target_ops): Update.
3872	(linux_process_target::core_of_thread): Define.
3873	* linux-low.h (class linux_process_target): Update.
3874	* lynx-low.cc (lynx_target_ops): Update.
3875	* nto-low.cc (nto_target_ops): Update.
3876	* win32-low.cc (win32_target_ops): Update.
3877
38782020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
3879
3880	Turn process_stratum_target's handle_monitor_command op into a
3881	method of process_target.
3882
3883	* target.h (struct process_stratum_target): Remove the target op.
3884	(class process_target): Add the target op.
3885	(target_handle_monitor_command): Update the macro.
3886	* target.cc (process_target::handle_monitor_command): Define.
3887
3888	Update the derived classes and callers below.
3889
3890	* server.cc (handle_query): Update.
3891	* linux-low.cc (linux_target_ops): Update.
3892	(linux_process_target::handle_monitor_command): Define.
3893	* linux-low.h (class linux_process_target): Update.
3894	* lynx-low.cc (lynx_target_ops): Update.
3895	* nto-low.cc (nto_target_ops): Update.
3896	* win32-low.cc (win32_target_ops): Update.
3897
38982020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
3899
3900	Turn process_stratum_target's handle_new_gdb_connection op into a
3901	method of process_target.
3902
3903	* target.h (struct process_stratum_target): Remove the target op.
3904	(class process_target): Add the target op.
3905	(target_handle_new_gdb_connection): Update the macro.
3906	* target.cc (process_target::handle_new_gdb_connection): Define.
3907
3908	Update the derived classes and callers below.
3909
3910	* linux-low.cc (linux_target_ops): Update.
3911	(linux_handle_new_gdb_connection): Turn into ...
3912	(linux_process_target::handle_new_gdb_connection): ... this.
3913	* linux-low.h (class linux_process_target): Update.
3914	* lynx-low.cc (lynx_target_ops): Update.
3915	* nto-low.cc (nto_target_ops): Update.
3916	* win32-low.cc (win32_target_ops): Update.
3917
39182020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
3919
3920	Turn process_stratum_target's supports_fork_events,
3921	supports_vfork_events, and supports_exec_events ops into methods
3922	of process_target.
3923
3924	* target.h (struct process_stratum_target): Remove the target ops.
3925	(class process_target): Add the target ops.
3926	(target_supports_fork_events): Update the macro.
3927	(target_supports_vfork_events): Update the macro.
3928	(target_supports_exec_events): Update the macro.
3929	* target.cc (process_target::supports_fork_events): Define.
3930	(process_target::supports_vfork_events): Define.
3931	(process_target::supports_exec_events): Define.
3932
3933	Update the derived classes and callers below.
3934
3935	* linux-low.cc (linux_target_ops): Update.
3936	(linux_supports_fork_events): Turn into ...
3937	(linux_process_target::supports_fork_events): ... this.
3938	(linux_supports_vfork_events): Turn into ...
3939	(linux_process_target::supports_vfork_events): ... this.
3940	(linux_supports_exec_events): Turn into ...
3941	(linux_process_target::supports_exec_events): ... this.
3942	* linux-low.h (class linux_process_target): Update.
3943	* lynx-low.cc (lynx_target_ops): Update.
3944	* nto-low.cc (nto_target_ops): Update.
3945	* win32-low.cc (win32_target_ops): Update.
3946
39472020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
3948
3949	Turn process_stratum_target's supports_multi_process op into a
3950	method of process_target.
3951
3952	* target.h (struct process_stratum_target): Remove the target op.
3953	(class process_target): Add the target op.
3954	* target.cc (process_target::supports_multi_process): Define.
3955	(target_supports_multi_process): Update.
3956
3957	Update the derived classes and callers below.
3958
3959	* linux-low.cc (linux_target_ops): Update.
3960	(linux_supports_multi_process): Turn into ...
3961	(linux_process_target::supports_multi_process): ... this.
3962	* linux-low.h (class linux_process_target): Update.
3963	* lynx-low.cc (lynx_target_ops): Update.
3964	* nto-low.cc (nto_target_ops): Update.
3965	* win32-low.cc (win32_target_ops): Update.
3966
39672020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
3968
3969	Turn process_stratum_target's supports_non_stop, async, and
3970	start_non_stop ops into methods of process_target.
3971
3972	* target.h (struct process_stratum_target): Remove the target ops.
3973	(class process_target): Add the target ops.
3974	(target_supports_non_stop): Update the macro.
3975	(target_async): Update the macro.
3976	(start_non_stop): Remove declaration.
3977	* target.cc (process_target::supports_non_stop): Define.
3978	(process_target::async): Define.
3979	(process_target::start_non_stop): Define.
3980	(start_non_stop): Remove.
3981
3982	Update the derived classes and callers below.
3983
3984	* server.cc (handle_qxfer_siginfo): Update.
3985	(handle_query): Update.
3986	* linux-low.cc (linux_target_ops): Update.
3987	(linux_supports_non_stop): Turn into ...
3988	(linux_process_target::supports_non_stop): ... this.
3989	(linux_async): Turn into ...
3990	(linux_process_target::async): ... this.
3991	(linux_start_non_stop): Turn into ...
3992	(linux_process_target::start_non_stop): ... this.
3993	* linux-low.h (class linux_process_target): Update.
3994	* lynx-low.cc (lynx_target_ops): Update.
3995	* nto-low.cc (nto_target_ops): Update.
3996	(nto_supports_non_stop): Remove; rely on the default behavior
3997	instead.
3998	* win32-low.cc (win32_target_ops): Update.
3999
40002020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
4001
4002	Turn process_stratum_target's qxfer_siginfo op into a method of
4003	process_target.
4004
4005	* target.h (struct process_stratum_target): Remove the target op.
4006	(class process_target): Add the target op.  Also add
4007	'supports_qxfer_siginfo'.
4008	* target.cc (process_target::qxfer_siginfo): Define.
4009	(process_target::supports_qxfer_siginfo): Define.
4010
4011	Update the derived classes and callers below.
4012
4013	* server.cc (handle_qxfer_siginfo): Update.
4014	(handle_query): Update.
4015	* linux-low.cc (linux_target_ops): Update.
4016	(linux_process_target::supports_qxfer_siginfo): Define.
4017	(linux_xfer_siginfo): Turn into ...
4018	(linux_process_target::qxfer_siginfo): ... this.
4019	* linux-low.h (class linux_process_target): Update.
4020	* lynx-low.cc (lynx_target_ops): Update.
4021	* nto-low.cc (nto_target_ops): Update.
4022	* win32-low.cc (win32_target_ops): Update.
4023
40242020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
4025
4026	Turn process_stratum_target's qxfer_osdata op into a method of
4027	process_target.
4028
4029	* target.h (struct process_stratum_target): Remove the target op.
4030	(class process_target): Add the target op.  Also add
4031	'supports_qxfer_osdata'.
4032	* target.cc (process_target::qxfer_osdata): Define.
4033	(process_target::supports_qxfer_osdata): Define.
4034
4035	Update the derived classes and callers below.
4036
4037	* server.cc (handle_qxfer_osdata): Update.
4038	(handle_query): Update.
4039	* linux-low.cc (linux_target_ops): Update.
4040	(linux_process_target::supports_qxfer_osdata): Define.
4041	(linux_qxfer_osdata): Turn into ...
4042	(linux_process_target::qxfer_osdata): ... this.
4043	* linux-low.h (class linux_process_target): Update.
4044	* lynx-low.cc (lynx_target_ops): Update.
4045	* nto-low.cc (nto_target_ops): Update.
4046	* win32-low.cc (win32_target_ops): Update.
4047
40482020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
4049
4050	Turn process_stratum_target's hostio_last_error op into a
4051	method of process_target.
4052
4053	* target.h (struct process_stratum_target): Remove the target op.
4054	(class process_target): Add the target op.
4055	* target.cc: Add "hostio.h" to includes.
4056	(process_target::hostio_last_error): Define.
4057
4058	Update the derived classes and callers below.
4059
4060	* hostio.cc (hostio_error): Update.
4061	* linux-low.cc: Remove "hostio.h" from includes.
4062	(linux_target_ops): Update.
4063	* lynx-low.cc (lynx_target_ops): Update.
4064	* nto-low.cc (nto_target_ops): Update.
4065	* win32-low.h (class win32_process_target): Update.
4066	* win32-low.cc (win32_target_ops): Update.
4067	(wince_hostio_last_error): Turn into ...
4068	(win32_process_target::hostio_last_error): ... this.
4069
40702020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
4071
4072	Turn process_stratum_target's get_tls_address op into a method of
4073	process_target.
4074
4075	* target.h (struct process_stratum_target): Remove the target op.
4076	(class process_target): Add the target op.  Also add
4077	'supports_get_tls_address'.
4078	* target.cc (process_target::get_tls_address): Define.
4079	(process_target::supports_get_tls_address): Define.
4080
4081	Update the derived classes and callers below.
4082
4083	* server.cc (handle_query): Update.
4084	* linux-low.cc (linux_target_ops): Update.
4085	(linux_process_target::supports_get_tls_address): Define.
4086	(linux_process_target::get_tls_address): Define.
4087	* linux-low.h (class linux_process_target): Update.
4088	* lynx-low.cc (lynx_target_ops): Update.
4089	* nto-low.cc (nto_target_ops): Update.
4090	* win32-low.cc (win32_target_ops): Update.
4091
40922020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
4093
4094	Turn process_stratum_target's read_offsets op into a method of
4095	process_target.
4096
4097	* target.h (struct process_stratum_target): Remove the target op.
4098	(class process_target): Add the target op.  Also add
4099	'supports_read_offsets'.
4100	* target.cc (process_target::read_offsets): Define.
4101	(process_target::supports_read_offsets): Define.
4102
4103	Update the derived classes and callers below.
4104
4105	* server.cc (handle_query): Update.
4106	* linux-low.cc (SUPPORTS_READ_OFFSETS): New #define directive.
4107	(linux_target_ops): Update.
4108	(linux_process_target::supports_read_offsets): Define.
4109	(linux_read_offsets): Turn into ...
4110	(linux_process_target::read_offsets): ... this.
4111	* linux-low.h (class linux_process_target): Update.
4112	* lynx-low.cc (lynx_target_ops): Update.
4113	* nto-low.cc (nto_target_ops): Update.
4114	* win32-low.cc (win32_target_ops): Update.
4115
41162020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
4117
4118	Turn process_stratum_target's stopped_by_watchpoint and
4119	stopped_data_address ops into methods of process_target.
4120
4121	* target.h (struct process_stratum_target): Remove the target ops.
4122	(class process_target): Add the target ops.
4123	* target.cc (process_target::stopped_by_watchpoint): Define.
4124	(process_target::stopped_data_address): Define.
4125
4126	Update the derived classes and callers below.
4127
4128	* remote-utils.cc (prepare_resume_reply): Update.
4129	* linux-low.cc (linux_target_ops): Update.
4130	(linux_stopped_by_watchpoint): Turn into ...
4131	(linux_process_target::stopped_by_watchpoint): ... this.
4132	(linux_stopped_data_address): Turn into ...
4133	(linux_process_target::stopped_data_address): ... this.
4134	* linux-low.h (class linux_process_target): Update.
4135	* lynx-low.cc (lynx_target_ops): Update.
4136	* nto-low.cc (nto_target_ops): Update.
4137	(nto_stopped_by_watchpoint): Turn into ...
4138	(nto_process_target::stopped_by_watchpoint): ... this.
4139	(nto_stopped_data_address): Turn into ...
4140	(nto_process_target::stopped_data_address): ... this.
4141	* nto-low.h (class nto_process_target): Update.
4142	* win32-low.cc (win32_target_ops): Update.
4143	(win32_stopped_by_watchpoint): Turn into ...
4144	(win32_process_target::stopped_by_watchpoint): ... this.
4145	(win32_stopped_data_address): Turn into ...
4146	(win32_process_target::stopped_data_address): ... this.
4147	* win32-low.h (class win32_process_target): Update.
4148
41492020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
4150
4151	Turn process_stratum_target's supports_hardware_single_step op into
4152	a method of process_target.
4153
4154	* target.h (struct process_stratum_target): Remove the target op.
4155	(class process_target): Add the target op.
4156	(target_supports_hardware_single_step): Update the macro.
4157	(target_can_do_hardware_single_step): Remove declaration.
4158	* target.cc (process_target::supports_hardware_single_step): Define.
4159	(target_can_do_hardware_single_step): Remove.
4160
4161	Update the derived classes and callers below.
4162
4163	* linux-low.h (class linux_process_target): Update.
4164	* linux-low.cc (linux_target_ops): Update.
4165	(linux_supports_hardware_single_step): Turn into ...
4166	(linux_process_target::supports_hardware_single_step): ... this.
4167	* lynx-low.h (class lynx_process_target): Update.
4168	* lynx-low.cc (lynx_target_ops): Update.
4169	(lynx_process_target::supports_hardware_single_step): Define.
4170	* nto-low.h (class nto_process_target): Update.
4171	* nto-low.cc (nto_target_ops): Update.
4172	(nto_process_target::supports_hardware_single_step): Define.
4173	* win32-low.h (class win32_process_target): Update.
4174	* win32-low.cc (win32_target_ops): Update.
4175	(win32_process_target::supports_hardware_single_step): Define.
4176
41772020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
4178
4179	Turn process_stratum_target's {supports_}stopped_by_hw_breakpoint
4180	ops into methods of process_target.
4181
4182	* target.h (struct process_stratum_target): Remove the target ops.
4183	(class process_target): Add the target ops.
4184	(target_stopped_by_hw_breakpoint): Update the macro.
4185	(target_supports_stopped_by_hw_breakpoint): Update the macro.
4186	* target.cc (process_target::stopped_by_hw_breakpoint): Define.
4187	(process_target::supports_stopped_by_hw_breakpoint): Define.
4188
4189	Update the derived classes and callers below.
4190
4191	* linux-low.cc (linux_target_ops): Update.
4192	(linux_stopped_by_hw_breakpoint): Turn into ...
4193	(linux_process_target::stopped_by_hw_breakpoint): ... this.
4194	(linux_supports_stopped_by_hw_breakpoint): Turn into ...
4195	(linux_process_target::supports_stopped_by_hw_breakpoint): ... this.
4196	* linux-low.h (class linux_process_target): Update.
4197	* lynx-low.cc (lynx_target_ops): Update.
4198	* nto-low.cc (nto_target_ops): Update.
4199	* win32-low.cc (win32_target_ops): Update.
4200
42012020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
4202
4203	Turn process_stratum_target's {supports_}stopped_by_sw_breakpoint
4204	ops into methods of process_target.
4205
4206	* target.h (struct process_stratum_target): Remove the target ops.
4207	(class process_target): Add the target ops.
4208	(target_stopped_by_sw_breakpoint): Update the macro.
4209	(target_supports_stopped_by_sw_breakpoint): Update the macro.
4210	* target.cc (process_target::stopped_by_sw_breakpoint): Define.
4211	(process_target::supports_stopped_by_sw_breakpoint): Define.
4212
4213	Update the derived classes and callers below.
4214
4215	* linux-low.cc (linux_target_ops): Update.
4216	(linux_stopped_by_sw_breakpoint): Turn into ...
4217	(linux_process_target::stopped_by_sw_breakpoint): ... this.
4218	(linux_supports_stopped_by_sw_breakpoint): Turn into ...
4219	(linux_process_target::supports_stopped_by_sw_breakpoint): ... this.
4220	* linux-low.h (class linux_process_target): Update.
4221	* lynx-low.cc (lynx_target_ops): Update.
4222	* nto-low.cc (nto_target_ops): Update.
4223	* win32-low.cc (win32_target_ops): Update.
4224
42252020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
4226
4227	Turn process_stratum_target's insert_point and remove_point ops
4228	into methods of process_target.
4229
4230	* target.h (struct process_stratum_target): Remove the target ops.
4231	(class process_target): Add the target ops.
4232	* target.cc (process_target::insert_point): Define.
4233	(process_target::remove_point): Define.
4234
4235	Update the derived classes and callers below.
4236
4237	* mem-break.cc (set_raw_breakpoint_at): Update.
4238	(delete_raw_breakpoint): Update.
4239	(uninsert_raw_breakpoint): Update.
4240	(reinsert_raw_breakpoint): Update.
4241	* linux-low.cc (linux_target_ops): Update.
4242	(linux_insert_point): Turn into ...
4243	(linux_process_target::insert_point): ... this.
4244	(linux_remove_point): Turn into ...
4245	(linux_process_target::remove_point): ... this.
4246	* linux-low.h (class linux_process_target): Update.
4247	* lynx-low.cc (lynx_target_ops): Update.
4248	* nto-low.cc (nto_target_ops): Update.
4249	(nto_insert_point): Turn into ...
4250	(nto_process_target::insert_point): ... this.
4251	(nto_remove_point): Turn into ...
4252	(nto_process_target::remove_point): ... this.
4253	* nto-low.h (class nto_process_target): Update.
4254	* win32-low.cc (win32_target_ops): Update.
4255	(win32_insert_point): Turn into ...
4256	(win32_process_target::insert_point): ... this.
4257	(win32_remove_point): Turn into ...
4258	(win32_process_target::remove_point): ... this.
4259	* win32-low.h (class win32_process_target): Update.
4260
42612020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
4262
4263	Turn process_stratum_target's supports_z_point_type op into a
4264	method of process_target.
4265
4266	* target.h (struct process_stratum_target): Remove the target op.
4267	(class process_target): Add the target op.
4268	* target.cc (process_target::supports_z_point_type): Define.
4269
4270	Update the derived classes and callers below.
4271
4272	* mem-break.cc (z_type_supported): Update.
4273	* linux-low.cc (linux_target_ops): Update.
4274	(linux_supports_z_point_type): Turn into ...
4275	(linux_process_target::supports_z_point_type): ... this.
4276	* linux-low.h (class linux_process_target): Update.
4277	* lynx-low.cc (lynx_target_ops): Update.
4278	* nto-low.cc (nto_target_ops): Update.
4279	(nto_supports_z_point_type): Turn into ...
4280	(nto_process_target::supports_z_point_type): ... this.
4281	* nto-low.h (class nto_process_target): Update.
4282	* win32-low.cc (win32_target_ops): Update.
4283	(win32_supports_z_point_type): Turn into ...
4284	(win32_process_target::supports_z_point_type): ... this.
4285	* win32-low.h (class win32_process_target): Update.
4286
42872020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
4288
4289	Turn process_stratum_target's read_auxv op into a method of
4290	process_target.
4291
4292	* target.h (class process_stratum_target): Remove the target op.
4293	(struct process_target): Add the target op.  Also add
4294	'supports_read_auxv'.
4295	* target.cc (process_target::read_auxv): Define.
4296	(process_target::supports_read_auxv): Define.
4297
4298	Update the derived classes and callers below.
4299
4300	* server.cc (handle_qxfer_auxv): Update.
4301	(handle_query): Update.
4302	* linux-low.cc (linux_target_ops): Update.
4303	(linux_process_target::supports_read_auxv): Define.
4304	(linux_read_auxv): Turn into ...
4305	(linux_process_target::read_auxv): ... this.
4306	* linux-low.h (class linux_process_target): Update.
4307	* lynx-low.cc (lynx_target_ops): Update.
4308	* nto-low.cc (nto_target_ops): Update.
4309	(nto_process_target::supports_read_auxv): Define.
4310	(nto_read_auxv): Turn into ...
4311	(nto_process_target::read_auxv): ... this.
4312	* nto-low.h (class nto_process_target): Update.
4313	* win32-low.cc (win32_target_ops): Update.
4314
43152020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
4316
4317	Turn process_stratum_target's request_interrupt op into a method of
4318	process_target.
4319
4320	* target.h (struct process_stratum_target): Remove the target op.
4321	(class process_target): Add the target op.
4322
4323	Update the derived classes and callers below.
4324
4325	* remote-utils.cc (putpkt_binary_1): Update.
4326	(input_interrupt): Update.
4327	(getpkt): Update.
4328	* server.cc (handle_v_requests): Update.
4329	* linux-low.cc (linux_target_ops): Update.
4330	(linux_request_interrupt): Turn into ...
4331	(linux_process_target::request_interrupt): ... this.
4332	* linux-low.h (class linux_process_target): Update.
4333	* lynx-low.cc (lynx_target_ops): Update.
4334	(lynx_request_interrupt): Turn into ...
4335	(lynx_process_target::request_interrupt): ... this.
4336	* lynx-low.h (class lynx_process_target): Update.
4337	* nto-low.cc (nto_target_ops): Update.
4338	(nto_request_interrupt): Turn into ...
4339	(nto_process_target::request_interrupt): ... this.
4340	* nto-low.h (class nto_process_target): Update.
4341	* win32-low.cc (win32_target_ops): Update.
4342	(win32_request_interrupt): Turn into ...
4343	(win32_process_target::request_interrupt): ... this.
4344	* win32-low.h (class win32_process_target): Update.
4345
43462020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
4347
4348	Turn process_stratum_target's look_up_symbols op into a method of
4349	process_target.
4350
4351	* target.h (struct process_stratum_target): Remove the target op.
4352	(class process_target): Add the target op.
4353	* target.cc (process_target::look_up_symbols): Define.
4354
4355	Update the derived classes and callers below.
4356
4357	* server.cc (handle_query): Update.
4358	* linux-low.cc (linux_target_ops): Update.
4359	(linux_look_up_symbols): Turn into ...
4360	(linux_process_target::look_up_symbols): ... this.
4361	* linux-low.h (class linux_process_target): Update.
4362	* lynx-low.cc (lynx_target_ops): Update.
4363	* nto-low.cc (nto_target_ops): Update.
4364	* win32-low.cc (win32_target_ops): Update.
4365
43662020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
4367
4368	Turn process_stratum_target's read_memory and write_memory
4369	ops into methods of process_target.
4370
4371	* target.h (struct process_stratum_target): Remove the target ops.
4372	(class process_target): Add the target ops.
4373
4374	Update the derived classes and callers below.
4375
4376	* linux-aarch32-low.cc (arm_breakpoint_at): Update.
4377	* linux-aarch64-low.cc (aarch64_breakpoint_at): Update.
4378	* linux-arm-low.cc (arm_sigreturn_next_pc): Update.
4379	(arm_get_syscall_trapinfo): Update.
4380	* linux-cris-low.cc (cris_breakpoint_at): Update.
4381	* linux-crisv32-low.cc (cris_breakpoint_at): Update.
4382	* linux-m32r-low.cc (m32r_breakpoint_at): Update.
4383	* linux-mips-low.cc (mips_breakpoint_at): Update.
4384	* linux-nios2-low.cc (nios2_breakpoint_at): Update.
4385	* linux-ppc-low.cc (ppc_breakpoint_at): Update.
4386	* linux-sh-low.cc (sh_breakpoint_at): Update.
4387	* linux-sparc-low.cc (sparc_fill_gregset_to_stack): Update.
4388	(sparc_store_gregset_from_stack): Update.
4389	(sparc_breakpoint_at): Update.
4390	* linux-tic6x-low.cc (tic6x_breakpoint_at): Update.
4391	* linux-tile-low.cc (tile_breakpoint_at): Update.
4392	* linux-x86-low.cc (x86_breakpoint_at): Update.
4393	* linux-xtensa-low.cc (xtensa_breakpoint_at): Update.
4394	* mem-brea.cc (insert_memory_breakpoint): Update.
4395	(validate_inserted_breakpoint): Update.
4396	* target.cc (read_inferior_memory): Update.
4397	(target_write_memory): Update.
4398	* linux-low.cc (linux_target_ops): Update.
4399	(linux_read_memory): Make a wrapper around the read_memory target
4400	op call.
4401	(linux_process_target::read_memory): Rename from linux_read_memory.
4402	(linux_write_memory): Turn into ...
4403	(linux_process_target::write_memory): ... this.
4404	* linux-low.h (class linux_process_target): Update.
4405	* lynx-low.cc (lynx_target_ops): Update.
4406	(lynx_read_memory): Turn into ...
4407	(lynx_process_target::read_memory): ... this.
4408	(lynx_write_memory): Turn into ...
4409	(lynx_process_target::write_memory): ... this.
4410	* lynx-low.h (class lynx_process_target): Update.
4411	* nto-low.cc (nto_target_ops): Update.
4412	(nto_read_memory): Turn into ...
4413	(nto_process_target::read_memory): ... this.
4414	(nto_write_memory): Turn into ...
4415	(nto_process_target::write_memory): ... this.
4416	* nto-low.h (class nto_process_target): Update.
4417	* win32-low.cc (win32_target_ops): Update.
4418	(win32_read_inferior_memory): Turn into ...
4419	(win32_process_target::read_memory): ... this.
4420	(win32_write_inferior_memory): Turn into ...
4421	(win32_process_target::write_memory): ... this.
4422	* win32-low.h (class win32_process_target): Update.
4423
44242020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
4425
4426	Turn process_stratum_target's prepare_to_access_memory and
4427	done_accessing_memory ops into methods of process_target.
4428
4429	* target.h (struct process_stratum_target): Remove the target ops.
4430	(class process_target): Add the target ops.
4431	* target.cc (process_target::prepare_to_access_memory): Define.
4432	(process_target::done_accessing_memory): Define.
4433	(prepare_to_access_memory): Update.
4434	(done_accessing_memory): Update.
4435
4436	Update the derived classes and callers below.
4437
4438	* linux-low.cc (linux_target_ops): Update.
4439	(linux_prepare_to_access_memory): Turn into ...
4440	(linux_process_target::prepare_to_access_memory): ... this.
4441	(linux_done_accessing_memory): Turn into ...
4442	(linux_process_target::done_accessing_memory): ... this.
4443	* linux-low.h (class linux_process_target): Update.
4444	* lynx-low.cc (lynx_target_ops): Update.
4445	* nto-low.cc (nto_target_ops): Update.
4446	* win32-low.cc (win32_target_ops): Update.
4447
44482020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
4449
4450	Turn process_stratum_target's fetch_registers and store_registers
4451	ops into methods of process_target.
4452
4453	* target.h (struct process_stratum_target): Remove the target ops.
4454	(class process_target): Add the target ops.
4455	(fetch_inferior_registers): Update the macro.
4456	(store_inferior_registers): Update the macro.
4457
4458	Update the derived classes and callers below.
4459
4460	* linux-low.cc (linux_target_ops): Update.
4461	(linux_fetch_registers): Turn into ...
4462	(linux_process_target::fetch_registers): ... this.
4463	(linux_store_registers): Turn into ...
4464	(linux_process_target::store_registers): ... this.
4465	* linux-low.h (class linux_process_target): Update.
4466	* lynx-low.cc (lynx_target_ops): Update.
4467	(lynx_fetch_registers): Turn into ...
4468	(lynx_process_target::fetch_registers): ... this.
4469	(lynx_store_registers): Turn into ...
4470	(lynx_process_target::store_registers): ... this.
4471	* lynx-low.h (class lynx_process_target): Update.
4472	* nto-low.cc (nto_target_ops): Update.
4473	(nto_fetch_registers): Turn into ...
4474	(nto_process_target::fetch_registers): ... this.
4475	(nto_store_registers): Turn into ...
4476	(nto_process_target::store_registers): ... this.
4477	* nto-low.h (class nto_process_target): Update.
4478	* win32-low.cc (win32_target_ops): Update.
4479	(win32_fetch_inferior_registers): Turn into ...
4480	(win32_process_target::fetch_registers): ... this.
4481	(win32_store_inferior_registers): Turn into ...
4482	(win32_process_target::store_registers): ... this.
4483	* win32-low.h (class win32_process_target): Update.
4484
44852020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
4486
4487	Turn process_stratum_target's wait op into a method of
4488	process_target.
4489
4490	* target.h (struct process_stratum_target): Remove the target op.
4491	(class process_target): Add the target op.
4492
4493	Update the derived classes and callers below.
4494
4495	* target.cc (target_wait): Update.
4496	* linux-low.cc (linux_target_ops): Update.
4497	(linux_wait): Turn into ...
4498	(linux_process_target::wait): ... this.
4499	* linux-low.h (class linux_process_target): Update.
4500	* lynx-low.cc (lynx_target_ops): Update.
4501	(lynx_wait): Turn into ...
4502	(lynx_process_target::wait): ... this.
4503	* lynx-low.h (class lynx_process_target): Update.
4504	* nto-low.cc (nto_target_ops): Update.
4505	(nto_wait): Turn into ...
4506	(nto_process_target::wait): ... this.
4507	* nto-low.h (class nto_process_target): Update.
4508	* win32-low.cc (win32_target_ops): Update.
4509	(win32_wait): Turn into ...
4510	(win32_process_target::wait): ... this.
4511	(do_initial_child_stuff): Update.
4512	* win32-low.h (class win32_process_target): Update.
4513
45142020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
4515
4516	Turn process_stratum_target's resume op into a method of
4517	process_target.
4518
4519	* target.h (struct process_stratum_target): Remove the target op.
4520	(class process_target): Add the target op.
4521
4522	Update the derived classes and callers below.
4523
4524	* server.cc (resume): Update.
4525	* target.cc (target_stop_and_wait): Update.
4526	(target_continue_no_signal): Update.
4527	(target_continue): Update.
4528	* linux-low.cc (linux_target_ops): Update.
4529	(linux_resume): Turn into ...
4530	(linux_process_target::resume): ... this.
4531	* linux-low.h (class linux_process_target): Update.
4532	* lynx-low.cc (lynx_target_ops): Update.
4533	(lynx_resume): Turn into ...
4534	(lynx_process_target::resume): ... this.
4535	* lynx-low.h (class lynx_process_target): Update.
4536	* nto-low.cc (nto_target_ops): Update.
4537	(nto_resume): Turn into ...
4538	(nto_process_target::resume): ... this.
4539	* nto-low.h (class nto_process_target): Update.
4540	* win32-low.cc (win32_target_ops): Update.
4541	(win32_resume): Turn into ...
4542	(win32_process_target::resume): ... this.
4543	(win32_process_target::detach): Update.
4544	(do_initial_child_stuff): Update.
4545	* win32-low.h (class win32_process_target): Update.
4546
45472020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
4548
4549	Turn process_stratum_target's thread_alive op into a method of
4550	process_target.
4551
4552	* target.h (struct process_stratum_target): Remove the target op.
4553	(class process_target): Add the target op.
4554	(mythread_alive): Update the macro.
4555
4556	Update the derived classes and callers below.
4557
4558	* linux-low.cc (linux_target_ops): Update.
4559	(linux_thread_alive): Turn into ...
4560	(linux_process_target::thread_alive): ... this.
4561	(wait_for_sigstop): Update.
4562	* linux-low.h (class linux_process_target): Update.
4563	* lynx-low.cc (lynx_target_ops): Update.
4564	(lynx_thread_alive): Turn into ...
4565	(lynx_process_target::thread_alive): ... this.
4566	* lynx-low.h (class lynx_process_target): Update.
4567	* nto-low.cc (nto_target_ops): Update.
4568	(nto_thread_alive): Turn into ...
4569	(nto_process_target::thread_alive): ... this.
4570	* nto-low.h (class nto_process_target): Update.
4571	* win32-low.cc (win32_target_ops): Update.
4572	(win32_thread_alive): Turn into ...
4573	(win32_process_target::thread_alive): ... this.
4574	* win32-low.h (class win32_process_target): Update.
4575
45762020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
4577
4578	Turn process_stratum_target's join op into a method of
4579	process_target.
4580
4581	* target.h (struct process_stratum_target): Remove the target op.
4582	(class process_target): Add the target op.
4583	(join_inferior): Update the macro.
4584
4585	Update the derived classes and callers below.
4586
4587	* linux-low.cc (linux_target_ops): Update.
4588	(linux_join): Turn into ...
4589	(linux_process_target::join): ... this.
4590	* linux-low.h (class linux_process_target): Update.
4591	* lynx-low.cc (lynx_target_ops): Update.
4592	(lynx_join): Turn into ...
4593	(lynx_process_target::join): ... this.
4594	* lynx-low.h (class lynx_process_target): Update.
4595	* nto-low.cc (nto_target_ops): Update.
4596	(nto_process_target::join): Define.
4597	* nto-low.h (class nto_process_target): Update.
4598	* win32-low.cc (win32_target_ops): Update.
4599	(win32_join): Turn into ...
4600	(win32_process_target::join): ... this.
4601	* win32-low.h (class win32_process_target): Update.
4602
46032020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
4604
4605	Turn process_stratum_target's mourn op into a method of
4606	process_target.
4607
4608	* target.h (struct process_stratum_target): Remove the target op.
4609	(class process_target): Add the target op.
4610
4611	Update the derived classes and callers below.
4612
4613	* target.cc (target_mourn_inferior): Update.
4614	* linux-low.cc (linux_target_ops): Update.
4615	(linux_mourn): Turn into ...
4616	(linux_process_target::mourn): ... this.
4617	(handle_extended_wait): Update.
4618	(linux_process_target::kill): Update.
4619	(linux_process_target::detach): Update.
4620	* linux-low.h (class linux_process_target): Update.
4621	* lynx-low.cc (lynx_target_ops): Update.
4622	(lynx_mourn): Turn into ...
4623	(lynx_process_target::mourn): ... this.
4624	* lynx-low.h (class lynx_process_target): Update.
4625	* nto-low.cc (nto_target_ops): Update.
4626	(nto_mourn): Turn into ...
4627	(nto_process_target::mourn): ... this.
4628	* nto-low.h (class nto_process_target): Update.
4629	* win32-low.cc (win32_target_ops): Update.
4630	(win32_mourn): Turn into ...
4631	(win32_process_target::mourn): ... this.
4632	* win32-low.h (class win32_process_target): Update.
4633
46342020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
4635
4636	Turn process_stratum_target's detach op into a method of
4637	process_target.
4638
4639	* target.h (struct process_stratum_target): Remove the target op.
4640	(class process_target): Add the target op.
4641	(detach_inferior): Update the macro.
4642
4643	Update the derived classes and callers below.
4644
4645	* linux-low.cc (linux_target_ops): Update.
4646	(linux_detach): Turn into ...
4647	(linux_process_target::detach): ... this.
4648	* linux-low.h (class linux_process_target): Update.
4649	* lynx-low.cc (lynx_target_ops): Update.
4650	(lynx_detach): Turn into ...
4651	(lynx_process_target::detach): ... this.
4652	* lynx-low.h (class lynx_process_target): Update.
4653	* nto-low.cc (nto_target_ops): Update.
4654	(nto_detach): Turn into ...
4655	(nto_process_target::detach): ... this.
4656	* nto-low.h (class nto_process_target): Update.
4657	* win32-low.cc (win32_target_ops): Update.
4658	(win32_detach): Turn into ...
4659	(win32_process_target::detach): ... this.
4660	* win32-low.h (class win32_process_target): Update.
4661
46622020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
4663
4664	Turn process_stratum_target's kill op into a method of
4665	process_target.
4666
4667	* target.h (struct process_stratum_target): Remove the target op.
4668	(class process_target): Add the target op.
4669
4670	Update the derived classes and callers below.
4671
4672	* target.cc (kill_inferior): Update.
4673	* linux-low.cc (linux_target_ops): Update.
4674	(linux_kill): Turn into ...
4675	(linux_process_target::kill): ... this.
4676	* linux-low.h (class linux_process_target): Update.
4677	* lynx-low.cc (lynx_target_ops): Update.
4678	(lynx_kill): Turn into ...
4679	(lynx_process_target::kill): ... this.
4680	* lynx-low.h (class lynx_process_target): Update.
4681	* nto-low.cc (nto_target_ops): Update.
4682	(nto_kill): Turn into ...
4683	(nto_process_target::kill): ... this.
4684	* nto-low.h (class nto_process_target): Update.
4685	* win32-low.cc (win32_target_ops): Update.
4686	(win32_kill): Turn into ...
4687	(win32_process_target::kill): ... this.
4688	* win32-low.h (class win32_process_target): Update.
4689
46902020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
4691
4692	Turn process_stratum_target's attach op into a method of
4693	process_target.
4694
4695	* target.h (struct process_stratum_target): Remove the target op.
4696	(class process_target): Add the target op.
4697	(myattach): Update the macro.
4698
4699	Update the derived classes and callers below.
4700
4701	* linux-low.cc (linux_target_ops): Update.
4702	(linux_attach): Turn into ...
4703	(linux_process_target::attach): ... this.
4704	* linux-low.h (class linux_process_target): Update.
4705	* lynx-low.cc (lynx_target_ops): Update.
4706	(lynx_attach): Turn into ...
4707	(lynx_process_target::attach): ... this.
4708	* lynx-low.h (class lynx_process_target): Update.
4709	* nto-low.cc (nto_target_ops): Update.
4710	(nto_attach): Turn into ...
4711	(nto_process_target::attach): ... this.
4712	* nto-low.h (class nto_process_target): Update.
4713	* win32-low.cc (win32_target_ops): Update.
4714	(win32_attach): Turn into ...
4715	(win32_process_target::attach): ... this.
4716	* win32-low.h (class win32_process_target): Update.
4717
47182020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
4719
4720	Turn process_stratum_target's post_create_inferior op into a method
4721	of process_target.
4722
4723	* target.h (struct process_stratum_target): Remove the target op.
4724	(class process_target): Add the target op.
4725	(target_post_create_inferior): Update the macro.
4726	* target.cc (process_target::post_create_inferior): Define.
4727
4728	Update the derived classes and callers below.
4729
4730	* linux-low.cc (linux_target_ops): Update.
4731	(linux_post_create_inferior): Turn into ...
4732	(linux_process_target::post_create_inferior): ... this.
4733	* linux-low.h (class linux_process_target): Update.
4734	* lynx-low.cc (lynx_target_ops): Update.
4735	* nto-low.cc (nto_target_ops): Update.
4736	* win32-low.cc (win32_target_ops): Update.
4737
47382020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
4739
4740	Turn process_stratum_target's create_inferior op into a method of
4741	process_target.
4742
4743	* target.h (struct process_stratum_target): Remove the target op.
4744	(class process_target): Add the target op.
4745	(create_inferior): Rename the macro to ...
4746	(target_create_inferior): ... this.
4747
4748	Update the derived classes and callers below.
4749
4750	* server.cc (handle_v_run): Update.
4751	(captured_main): Update.
4752	(process_serial_event): Update.
4753	* linux-low.cc (linux_target_ops): Update.
4754	(linux_create_inferior): Turn into ...
4755	(linux_process_target::create_inferior): ... this.
4756	* linux-low.h (class linux_process_target): Update.
4757	* lynx-low.cc (lynx_target_ops): Update.
4758	(lynx_create_inferior): Turn into ...
4759	(lynx_process_target::create_inferior): ... this.
4760	* lynx-low.h (class lynx_process_target): Update.
4761	* nto-low.cc (nto_target_ops): Update.
4762	(nto_create_inferior): Turn into ...
4763	(nto_process_target::create_inferior): ... this.
4764	* nto-low.h (class nto_process_target): Update.
4765	* win32-low.cc (win32_target_ops): Update.
4766	(win32_create_inferior): Turn into ...
4767	(win32_process_target::create_inferior): ... this.
4768	* win32-low.h (class win32_process_target): Update.
4769
47702020-02-20  Tankut Baris Aktemur  <tankut.baris.aktemur@intel.com>
4771
4772	* target.h (class process_target): New class definition.
4773	(struct process_stratum_target) <pt>: New field with type
4774	'process_target*'.
4775	* linux-low.h (class linux_process_target): Define as a derived
4776	class of 'process_target'.
4777	* linux-low.cc (linux_target_ops): Add a linux_process_target*
4778	as the 'pt' field.
4779	* lynx-low.h (class lynx_process_target): Define as a derived
4780	class of 'process_target'.
4781	* lynx-low.cc (lynx_target_ops): Add a lynx_process_target*
4782	as the 'pt' field.
4783	* nto-low.h (class nto_process_target): Define as a derived
4784	class of 'process_target'.
4785	* nto-low.cc (nto_target_ops): Add an nto_process_target*
4786	as the 'pt' field.
4787	* win32-low.h (class win32_process_target): Define as a derived
4788	class of 'process_target'.
4789	* win32-low.cc (win32_target_ops): Add a win32_process_target*
4790	as the 'pt' field.
4791
47922020-02-19  Andrew Burgess  <andrew.burgess@embecosm.com>
4793
4794	* configure: Regenerate.
4795
47962020-02-19  Maciej W. Rozycki  <macro@wdc.com>
4797	    Andrew Burgess  <andrew.burgess@embecosm.com>
4798
4799	* linux-riscv-low.cc: New file.
4800	* Makefile.in (SFILES): Add linux-riscv-low.cc, arch/riscv.c,
4801	and nat/riscv-linux-tdesc.c.
4802	* configure.srv <riscv*-*-linux*> (srv_tgtobj)
4803	(srv_linux_regsets, srv_linux_usrregs, srv_linux_thread_db):
4804	Define.
4805
48062020-02-14  Tom Tromey  <tom@tromey.com>
4807
4808	* acinclude.m4: Don't include acx_configure_dir.m4.
4809	* Makefile.in (LIBIBERTY_BUILDDIR, GNULIB_BUILDDIR): Update.
4810	(SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): Remove.
4811	(all, install-only, uninstall, clean-info, clean)
4812	(maintainer-clean): Don't recurse.
4813	(subdir_do, all-lib): Remove.
4814	($(LIBGNU) $(LIBIBERTY) $(GNULIB_H)): Remove rule.
4815	(GNULIB_H): Remove.
4816	(generated_files): Update.
4817	($(GNULIB_BUILDDIR)/Makefile): Remove rule.
4818	* configure: Rebuild.
4819	* configure.ac: Don't configure gnulib or libiberty.
4820	(GNULIB): Update.
4821
48222020-02-14  Eli Zaretskii  <eliz@gnu.org>
4823
4824	* win32-low.c (create_process): Prepend PROGRAM to ARGS when
4825	preparing the command line for CreateProcess.
4826	(win32_create_inferior): Reflect the program name in debugging
4827	output that shows the process and its command line.
4828
48292020-02-13  Simon Marchi  <simon.marchi@efficios.com>
4830
4831	* Makefile.in: Rename source files from .c to .cc.
4832	* %.c: Rename to %.cc.
4833	* configure.ac: Rename server.c to server.cc.
4834	* configure: Re-generate.
4835
48362020-02-13  Simon Marchi  <simon.marchi@efficios.com>
4837
4838	* Makefile.in: Rename gdbsupport source files from .c to .cc.
4839
48402020-02-12  Hannes Domani  <ssbssa@yahoo.de>
4841
4842	* win32-low.c (win32_create_inferior): Set signal_pid.
4843
48442020-02-12  Maciej W. Rozycki <macro@wdc.com>
4845	    Pedro Alves  <palves@redhat.com>
4846
4847	Skip building gdbserver in a cross-configuration.
4848	* configure.srv: Set $gdbserver_host depending on whether $target
4849	is $host.  Use $gdbserver_host instead of $host.
4850
48512020-02-11  Simon Marchi  <simon.marchi@efficios.com>
4852
4853	* configure: Re-generate.
4854
48552020-02-11  Simon Marchi  <simon.marchi@efficios.com>
4856
4857	* configure: Re-generate.
4858
48592020-02-11  Simon Marchi  <simon.marchi@efficios.com>
4860
4861	* acinclude.m4: Update warning.m4 path.
4862
48632020-02-09  Hannes Domani  <ssbssa@yahoo.de>
4864
4865	* win32-low.c (win32_clear_inferiors): Reset siginfo_er.
4866	(handle_exception): Set siginfo_er.
4867	(win32_xfer_siginfo): New function.
4868
48692020-02-07  Tom Tromey  <tom@tromey.com>
4870	    Pedro Alves  <palves@redhat.com>
4871
4872	* README: Update build documentation.
4873	* configure.srv: Set UNSUPPORTED if host is unsupported.  Check
4874	host, not target.
4875	* configure.ac: Update paths.
4876	* configure: Rebuild.
4877	* acinclude.m4: Update paths.
4878	* Makefile.in: Update include paths.
4879	(depcomp, INCLUDE_DIR, INCGNU, INCSUPPORT, INCLUDE_CFLAGS)
4880	(SFILES, XML_DIR, n, $(GNULIB_BUILDDIR)/Makefile, config.status)
4881	(version-generated.c, stamp-xml, regdat_sh, arch/%-ipa.o)
4882	(gdbsupport/%-ipa.o, %-ipa.o, arch/%.o, gdbsupport/%.o, %.o)
4883	(%-generated.c): Update paths.
4884	* Move entire directory from ../gdb/gdbserver.
4885
48862020-01-29  Maciej W. Rozycki  <macro@wdc.com>
4887
4888	* configure.srv <i[34567]86-*-mingw*>: Fix whitespace damage.
4889
48902020-01-29  Pedro Franco de Carvalho  <pedromfc@linux.ibm.com>
4891
4892	* configure.srv (powerpc*-*-linux*): Use srv_tgtobj in second
4893	assignment instead of srv_linux_obj.
4894
48952020-01-28  Hannes Domani  <ssbssa@yahoo.de>
4896
4897	* server.c (handle_qxfer_libraries): Write segment-address with
4898	paddress.
4899
49002020-01-24  Hannes Domani  <ssbssa@yahoo.de>
4901
4902	* Makefile.in (install-strip): New target.
4903	(install_sh, INSTALL_STRIP_PROGRAM, STRIP): New variables.
4904	* aclocal.m4: Regenerate.
4905	* configure: Regenerate.
4906	* configure.ac: Add AM_PROG_INSTALL_STRIP.
4907
49082020-01-24  Maciej W. Rozycki  <macro@wdc.com>
4909
4910	* Makefile.in (SFILES): Adjust paths to point to real files.
4911	(OBS): Move waitstatus.o to target/waitstatus.o.
4912	(TAGS): Transform paths appropriately.
4913	(%.o): Rename to...
4914	(nat/%.o): ... this pattern rule.
4915	(%.o): Rename to...
4916	(target/%.o): ... this pattern rule.
4917	* configure.srv: Adjust paths throughout to include nat/ prefix
4918	with the revant files.
4919	* configure.ac: Add `nat' and `target' to CONFIG_SRC_SUBDIR.
4920	* configure: Regenerate.
4921
49222020-01-24  Maciej W. Rozycki  <macro@wdc.com>
4923
4924	* Makefile.in (TAGS): Remove config files from the recipe.
4925
49262020-01-14  Tom Tromey  <tom@tromey.com>
4927
4928	* configure: Rebuild.
4929	* configure.ac: Remove any checks that were added to common.m4.
4930	* acinclude.m4: Include lib-ld.m4, lib-prefix.m4, and
4931	lib-link.m4.
4932
49332020-01-14  Tom Tromey  <tom@tromey.com>
4934
4935	* server.h: Include config.h.
4936	* gdbreplay.c: Include config.h.
4937	* configure: Rebuild.
4938	* configure.ac: Don't source common.host.
4939	* acinclude.m4: Update path.
4940	* Makefile.in (INCSUPPORT): New variable.
4941	(INCLUDE_CFLAGS): Add INCSUPPORT.
4942	(SFILES): Update paths.
4943	(version-generated.c): Update path to create-version.sh.
4944	(gdbsupport/%-ipa.o, gdbsupport/%.o): Update paths.
4945
49462020-01-14  Tom Tromey  <tom@tromey.com>
4947
4948	* configure.ac (LIBS): Use WIN32APILIBS.
4949	(USE_WIN32API): Don't define.
4950	* configure: Rebuild.
4951
49522020-01-14  Tom Tromey  <tom@tromey.com>
4953
4954	* configure: Rebuild.
4955
49562020-01-13  Simon Marchi  <simon.marchi@efficios.com>
4957
4958	* Makefile.in (%-generated.c): Remove rule for files from
4959	regformats/i386.
4960
49612020-01-13  Simon Marchi  <simon.marchi@efficios.com>
4962
4963	* configure: Re-generate.
4964
49652020-01-13  Simon Marchi  <simon.marchi@efficios.com>
4966
4967	* tracepoint.h (IP_AGENT_EXPORT_FUNC) [!IN_PROCESS_AGENT]:
4968	Define to static.
4969	* tracepoint.c (stop_tracing, flush_trace_buffer,
4970	about_to_request_buffer_space, get_trace_state_variable_value,
4971	set_trace_state_variable_value, gdb_collect): Add declaration.
4972
49732020-01-13  Simon Marchi  <simon.marchi@efficios.com>
4974
4975	* linux-x86-low.c (x86_linux_regs_info, amd64_emit_eq_goto,
4976	amd64_emit_ne_goto, amd64_emit_lt_goto, amd64_emit_le_goto,
4977	amd64_emit_gt_goto, amd64_emit_ge_goto, amd64_emit_ge_goto,
4978	i386_emit_eq_goto, i386_emit_ne_goto, i386_emit_lt_goto,
4979	i386_emit_le_goto, i386_emit_gt_goto, i386_emit_ge_goto): Make
4980	static.
4981
49822020-01-13  Simon Marchi  <simon.marchi@efficios.com>
4983
4984	* inferiors.c: Include gdbsupport/common-inferior.h.
4985
49862020-01-13  Simon Marchi  <simon.marchi@efficios.com>
4987
4988	* hostio-errno.c: Include hostio.h.
4989
49902020-01-13  Simon Marchi  <simon.marchi@efficios.com>
4991
4992	* Makefile.in (%-generated.c): Make $(regdat_sh) a regular
4993	prerequisite.
4994
49952020-01-12  Simon Marchi  <simon.marchi@polymtl.ca>
4996
4997	* linux-arm-tdesc.c: Include linux-arm-tdesc.h.
4998	* linux-arm-tdesc.h: Include arch/arm.h.
4999
50002020-01-12  Simon Marchi  <simon.marchi@polymtl.ca>
5001
5002	* linux-aarch64-low.c (aarch64_write_goto_address): Make static.
5003
50042020-01-12  Simon Marchi  <simon.marchi@polymtl.ca>
5005
5006	* linux-aarch32-tdesc.c: Include linux-aarch32-tdesc.h.
5007	* linux-aarch64-tdesc.c: Include linux-aarch64-tdesc.h.
5008
50092020-01-10  Pedro Alves  <palves@redhat.com>
5010
5011	* fork-child.c (post_fork_inferior): Pass target down to
5012	startup_inferior.
5013	* inferiors.c (switch_to_thread): Add process_stratum_target
5014	parameter.
5015	* lynx-low.c (lynx_target_ops): Now a process_stratum_target.
5016	* nto-low.c (nto_target_ops): Now a process_stratum_target.
5017	* linux-low.c (linux_target_ops): Now a process_stratum_target.
5018	* remote-utils.c (prepare_resume_reply): Pass the target to
5019	switch_to_thread.
5020	* target.c (the_target): Now a process_stratum_target.
5021	(done_accessing_memory): Pass the target to switch_to_thread.
5022	(set_target_ops): Ajust to use process_stratum_target.
5023	* target.h (struct target_ops): Rename to ...
5024	(struct process_stratum_target): ... this.
5025	(the_target, set_target_ops): Adjust.
5026	(prepare_to_access_memory): Adjust comment.
5027	* win32-low.c (child_xfer_memory): Adjust to use
5028	process_stratum_target.
5029	(win32_target_ops): Now a process_stratum_target.
5030
50312020-01-06  Eli Zaretskii  <eliz@gnu.org>
5032	    Pedro Alves  <palves@redhat.com>
5033
5034	* win32-low.c (get_child_debug_event): Extract the fatal exception
5035	from the exit status and convert to the equivalent Posix signal
5036	number.
5037	(win32_wait): Allow TARGET_WAITKIND_SIGNALLED status as well.
5038	* Makefile.in (OBS, SFILES): Add gdb_wait.[co].
5039
50402020-01-01  Hannes Domani  <ssbssa@yahoo.de>
5041
5042	* Makefile.in: Use INSTALL_PROGRAM_ENV.
5043
50442020-01-01  Joel Brobecker  <brobecker@adacore.com>
5045
5046	* server.c (gdbserver_version): Change copyright year to 2020.
5047	* gdbreplay.c (gdbreplay_version): Likewise.
5048
50492019-12-19  Christian Biesinger  <cbiesinger@google.com>
5050
5051	* configure: Regenerate.
5052	* configure.ac: Quote variable arguments of test.
5053
50542019-12-16  Bernd Edlinger  <bernd.edlinger@hotmail.de>
5055
5056	* Makefile.in: Fix build with GNU Make 3.81
5057
50582019-12-16  Tom Tromey  <tromey@adacore.com>
5059
5060	* server.c (get_exec_file): Constify result.
5061
50622019-12-10  Christian Biesinger  <cbiesinger@google.com>
5063
5064	* Makefile.in: Add safe-strerror.c to gdbreplay and IPA, and change
5065	UNDO_GNULIB_CFLAGS to undo strerror_r instead of strerror.
5066	* config.in: Regenerate.
5067	* configure: Regenerate.
5068	* configure.ac: Don't check for strerror.
5069	* linux-i386-ipa.c (initialize_fast_tracepoint_trampoline_buffer):
5070	Call safe_strerror instead of strerror.
5071	* server.h (strerror): Remove this now-unnecessary declaration.
5072	* tracepoint.c (init_named_socket): Call safe_strerror instead of
5073	strerror.
5074	(gdb_agent_helper_thread): Likewise.
5075	* utils.c (perror_with_name): Likewise.
5076
50772019-11-26  Tom Tromey  <tom@tromey.com>
5078
5079	* configure, config.in: Rebuild.
5080
50812019-11-26  Tom Tromey  <tom@tromey.com>
5082
5083	* remote-utils.c (block_unblock_async_io): Use gdb_sigmask.
5084	* linux-low.c (linux_wait_for_event_filtered, linux_async): Use
5085	gdb_sigmask.
5086	* configure, config.in: Rebuild.
5087
50882019-11-26  Tom Tromey  <tom@tromey.com>
5089
5090	* Makefile.in (PTHREAD_CFLAGS, PTHREAD_LIBS): New variables.
5091	(INTERNAL_CFLAGS_BASE): Use PTHREAD_CFLAGS.
5092	(GDBSERVER_LIBS): Use PTHREAD_LIBS.
5093	* acinclude.m4: Include ax_pthread.m4.
5094	* config.in, configure: Rebuild.
5095
50962019-11-26  Christian Biesinger  <cbiesinger@google.com>
5097
5098	* debug.c (debug_set_output): Call safe_strerror instead of
5099	strerror.
5100	* linux-low.c (attach_proc_task_lwp_callback): Likewise.
5101	(linux_kill_one_lwp): Likewise.
5102	(linux_detach_one_lwp): Likewise.
5103	(linux_wait_for_event_filtered): Likewise.
5104	(store_register): Likewise.
5105	* lynx-low.c (lynx_attach): Likewise.
5106	* mem-break.c (insert_memory_breakpoint): Likewise.
5107	(remove_memory_breakpoint): Likewise.
5108	(delete_fast_tracepoint_jump): Likewise.
5109	(set_fast_tracepoint_jump): Likewise.
5110	(uninsert_fast_tracepoint_jumps_at): Likewise.
5111	(reinsert_fast_tracepoint_jumps_at): Likewise.
5112	* nto-low.c (nto_xfer_memory): Likewise.
5113	(nto_resume): Likewise.
5114
51152019-11-20  Luis Machado  <luis.machado@linaro.org>
5116
5117	* linux-aarch64-low.c (is_sve_tdesc): Check against target feature
5118	instead of register count.
5119	* tdesc.c (tdesc_contains_feature): New function.
5120	* tdesc.h (tdesc_contains_feature): New prototype.
5121
51222019-11-15  Christian Biesinger  <cbiesinger@google.com>
5123
5124	* Makefile.in: Add safe-strerror.c.
5125	* configure: Regenerate.
5126	* configure.ac: Don't source common.host.
5127
51282019-11-15  Christian Biesinger  <cbiesinger@google.com>
5129
5130	* config.in: Regenerate.
5131	* configure: Regenerate.
5132
51332019-11-12  Andrew Burgess  <andrew.burgess@embecosm.com>
5134
5135	* ax.c (ax_printf): Handle size_t_arg.
5136
51372019-11-06  Christian Biesinger  <cbiesinger@google.com>
5138
5139	* linux-tdep.c (linux_info_proc): Use strtok_r instead of strtok.
5140	* mi/mi-main.c (output_cores): Likewise.
5141	* nat/linux-osdata.c (linux_xfer_osdata_cpus): Likewise.
5142	(linux_xfer_osdata_modules): Likewise.
5143	* remote.c (register_remote_support_xml): Likewise.
5144	* sparc64-tdep.c (adi_is_addr_mapped): Likewise.
5145	* xml-syscall.c (syscall_create_syscall_desc): Likewise.
5146
51472019-11-01  Christian Biesinger  <cbiesinger@google.com>
5148
5149	* configure: Regenerate.
5150	* configure.ac: Remove check for strerror_r.
5151
51522019-10-31  Christian Biesinger  <cbiesinger@google.com>
5153
5154	* config.in: Regenerate.
5155	* configure: Regenerate.
5156	* configure.ac: Also check for strerror_r.
5157
51582019-10-31  Christian Biesinger  <cbiesinger@google.com>
5159
5160	* ax.h (debug_agent): Remove duplicate declaration.
5161
51622019-10-26  Tom de Vries  <tdevries@suse.de>
5163
5164	* linux-aarch64-low.c: Fix typos in comments.
5165	* linux-arm-low.c: Same.
5166	* linux-low.c: Same.
5167	* linux-ppc-low.c: Same.
5168	* proc-service.c: Same.
5169	* regcache.h: Same.
5170	* server.c: Same.
5171	* tracepoint.c: Same.
5172	* win32-low.c: Same.
5173
51742019-10-25  Tom Tromey  <tromey@adacore.com>
5175
5176	* utils.c (xstrdup): Remove.
5177
51782019-10-23  Tom Tromey  <tom@tromey.com>
5179
5180	* configure, config.in: Rebuild.
5181
51822019-10-23  Tom Tromey  <tom@tromey.com>
5183
5184	* configure: Rebuild.
5185	* acinclude.m4: Use m4_include, not sinclude.
5186
51872019-10-17  Tom Tromey  <tromey@adacore.com>
5188
5189	* configure: Rebuild.
5190	* configure.ac: Use AC_CONFIG_HEADERS.  Create stamp-h there, not
5191	in AC_CONFIG_FILES invocation.
5192	* Makefile.in (stamp-h, Makefile): Use new-style config.status
5193	invocation.
5194
51952019-10-16  Christian Biesinger  <cbiesinger@google.com>
5196
5197	* server.c: Include xml-builtin.h.
5198	(get_xml_features): Don't declare xml_builtins here.
5199
52002019-10-15  Andrew Burgess  <andrew.burgess@embecosm.com>
5201
5202	* Makefile.in: Remove references to vec-ipa.o.
5203
52042019-10-15  Andrew Burgess  <andrew.burgess@embecosm.com>
5205
5206	* Makefile.in: Remove references to vec.c.
5207
52082019-10-02  Christian Biesinger  <cbiesinger@google.com>
5209
5210	* server.c (server_waiting): Change to bool.
5211	(extended_protocol): Likewise.
5212	(response_needed): Likewise.
5213	(exit_requested): Likewise.
5214	(run_once): Likewise.
5215	(report_no_resumed): Likewise.
5216	(non_stop): Likewise.
5217	(disable_packet_vCont): Likewise.
5218	(disable_packet_Tthread): Likewise.
5219	(disable_packet_qC): Likewise.
5220	(disable_packet_qfThreadInfo): Likewise.
5221	(handle_general_set): Update.
5222	(handle_detach): Update.
5223	(handle_monitor_command): Update.
5224	(handle_query): Update.
5225	(captured_main): Update.
5226	(process_serial_event): Update.
5227	* server.h (server_waiting): Change to bool.
5228	(disable_packet_vCont): Likewise.
5229	(disable_packet_Tthread): Likewise.
5230	(disable_packet_qC): Likewise.
5231	(disable_packet_qfThreadInfo): Likewise.
5232	(run_once): Likewise.
5233	(non_stop): Likewise.
5234	* target.c (target_stop_and_wait): Update.
5235
52362019-10-02  Tom Tromey  <tromey@adacore.com>
5237
5238	* Makefile.in (SFILES): Add common-inferior.c.
5239	(OBS): Add common-inferior.o.
5240	* server.c (startup_with_shell): Don't define.
5241
52422019-10-02  Andrew Burgess  <andrew.burgess@embecosm.com>
5243
5244	* linux-low.c (linux_low_read_btrace): Update for change to
5245	std::vector.
5246
52472019-09-20  Christian Biesinger  <cbiesinger@google.com>
5248
5249	* debug.c (debug_threads): Remove comment in favor of the header.
5250	* debug.h (using_threads): Add declaration.
5251	(debug_threads): Add comment.
5252	* linux-aarch64-low.c: Include debug.h and remove declaration of
5253	debug_threads.
5254	* nto-low.c: Likewise.
5255	* remote-utils.c: Likewise.
5256	* thread-db.c: Likewise.
5257
52582019-09-20  Ulrich Weigand  <uweigand@de.ibm.com>
5259
5260	* configure.srv (ipa_ppc_linux_regobj): Remove powerpc-cell32l-ipa.o
5261	and powerpc-cell64l-ipa.o.
5262	(powerpc*-*-linux*): Remove powerpc-cell32l.o and powerpc-cell64l.o
5263	from srv_regobj.  Remove rs6000/powerpc-cell32l.xml and
5264	rs6000/powerpc-cell64l.xml from srv_xmlfiles.
5265	(spu*-*-*): Remove.
5266
5267	* spu-low.c: Remove file.
5268
5269	* linux-ppc-low.c (INSTR_SC, NR_spu_run): Remove.
5270	(parse_spufs_run): Remove.
5271	(ppc_get_pc): Remove Cell/B.E. support.
5272	(ppc_set_pc): Likewise.
5273	(ppc_breakpoint_at): Likewise.
5274	(ppc_arch_setup): Likewise.
5275	(ppc_get_ipa_tdesc_idx): Do not handle tdesc_powerpc_cell64l or
5276	tdesc_powerpc_cell32l.
5277	(initialize_low_arch): Do not call init_registers_powerpc_cell64l
5278	or init_registers_powerpc_cell32l.
5279	* linux-ppc-ipa.c (get_ipa_tdesc): Do not handle PPC_TDESC_CELL.
5280	(initialize_low_tracepoint): Do not call init_registers_powerpc_cell64l
5281	or init_registers_powerpc_cell32l.
5282	* linux-ppc-tdesc-init.h (PPC_TDESC_CELL): Mark as unused.
5283	(init_registers_powerpc_cell32l): Remove prototype.
5284	(init_registers_powerpc_cell64l): Likewise.
5285
5286	* target.h (struct target_ops): Remove qxfer_spu member.
5287	* server.c (handle_qxfer_spu): Remove.
5288	(qxfer_packets): Remove entry for "spu".
5289	(handle_query): No longer support qXfer:spu:read or qXfer:spu:write.
5290	* linux-low.c (SPUFS_MAGIC): Remove.
5291	(spu_enumerate_spu_ids): Remove.
5292	(linux_qxfer_spu): Remove.
5293	(linux_target_ops): Remove qxfer_spu member.
5294	* lynx-low.c (lynx_target_ops): Remove qxfer_spu member.
5295	* nto-low.c (nto_target_ops): Remove qxfer_spu member.
5296	* win32-low.c (win32_target_ops): Remove qxfer_spu member.
5297
52982019-08-23  Sergio Durigan Junior  <sergiodj@redhat.com>
5299
5300	* Makefile.in (SFILES): Add 'gdbsupport/gdb-dlfcn.c'.
5301	(OBS): Add 'gdbsupport/gdb-dlfcn.o'.
5302	* config.in: Regenerate.
5303	* configure: Regenerate.
5304
53052019-08-15  Tom Tromey  <tromey@adacore.com>
5306
5307	* target.c (target_write_memory): Use gdb::byte_vector.
5308
53092019-08-15  Tom Tromey  <tromey@adacore.com>
5310
5311	* tracepoint.c (write_inferior_data_pointer)
5312	(write_inferior_integer, write_inferior_int8)
5313	(write_inferior_uinteger, m_tracepoint_action_download)
5314	(r_tracepoint_action_download, x_tracepoint_action_download)
5315	(l_tracepoint_action_download, clear_inferior_trace_buffer)
5316	(download_agent_expr, download_tracepoint_1)
5317	(download_trace_state_variables, upload_fast_traceframes): Update.
5318	* server.c (gdb_write_memory): Update.
5319	* remote-utils.c (relocate_instruction): Update.
5320	* proc-service.c (ps_pdwrite): Update.
5321	* mem-break.c (remove_memory_breakpoint)
5322	(delete_fast_tracepoint_jump, set_fast_tracepoint_jump)
5323	(uninsert_fast_tracepoint_jumps_at)
5324	(reinsert_fast_tracepoint_jumps_at): Update.
5325	* linux-x86-low.c (append_insns)
5326	(i386_install_fast_tracepoint_jump_pad)
5327	(amd64_write_goto_address, i386_write_goto_address): Update.
5328	* linux-s390-low.c (append_insns, s390_write_goto_address):
5329	Update.
5330	* linux-ppc-low.c (ppc_relocate_instruction)
5331	(ppc_install_fast_tracepoint_jump_pad, emit_insns)
5332	(ppc_write_goto_address): Update.
5333	* linux-aarch64-low.c (append_insns): Update.
5334	* target.h (struct target_ops): Update.
5335	(write_inferior_memory): Don't declare.
5336	* target.c (target_write_memory): Rename from
5337	write_inferior_memory.  Remove old target_write_memory.
5338
53392019-08-15  Tom Tromey  <tromey@adacore.com>
5340
5341	* target.c (write_inferior_memory): Use std::vector.
5342
53432019-08-06  Frank Ch. Eigler  <fche@redhat.com>
5344
5345	PR build/24886
5346	* configure.ac: Drop enable-libmcheck support.
5347	* configure, config.in: Rebuild.
5348	* acinclude.m4: Don't include it.
5349
53502019-07-19  Alan Hayward  <alan.hayward@arm.com>
5351
5352	* configure.srv: Remove Arm xml files.
5353
53542019-07-19  Alan Hayward  <alan.hayward@arm.com>
5355
5356	* configure.srv: Add new files. Remove xml generated files.
5357	* linux-aarch32-low.c (initialize_low_arch_aarch32): Don't init
5358	registers.
5359	* linux-aarch32-low.h (tdesc_arm_with_neon): Remove.
5360	* linux-aarch32-tdesc.c: New file.
5361	* linux-aarch32-tdesc.h: New file.
5362	* linux-aarch64-low.c (aarch64_arch_setup): Call aarch32_linux_read_description.
5363	* linux-arm-low.c (init_registers_arm, tdesc_arm)
5364	(init_registers_arm_with_iwmmxt, tdesc_arm_with_iwmmxt)
5365	(init_registers_arm_with_vfpv2, tdesc_arm_with_vfpv2)
5366	(init_registers_arm_with_vfpv3, tdesc_arm_with_vfpv3): Remove.
5367	(arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
5368	(arm_store_vfpregset): Call arm_linux_get_tdesc_fp_type.
5369	(arm_read_description): Call arm_linux_read_description.
5370	(initialize_low_arch): Don't init registers.
5371	* linux-arm-tdesc.c: New file.
5372	* linux-arm-tdesc.h: New file.
5373
53742019-07-10  Alan Hayward  <alan.hayward@arm.com>
5375
5376	* linux-arm-low.c (arm_fill_wmmxregset, arm_store_wmmxregset):
5377	Move counter inside for.
5378	(arm_read_description): Check ptrace earlier.
5379	(arm_arch_setup): Call arm_linux_init_hwbp_cap here.
5380
53812019-07-09  Tom Tromey  <tom@tromey.com>
5382
5383	* configure: Rebuild.
5384	* configure.ac: Change common to gdbsupport.
5385	* acinclude.m4: Change common to gdbsupport.
5386	* Makefile.in (SFILES, OBS, GDBREPLAY_OBS, IPA_OBJS)
5387	(version-generated.c, gdbsupport/%-ipa.o, gdbsupport/%.o): Change
5388	common to gdbsupport.
5389	* ax.c, event-loop.c, fork-child.c, gdb_proc_service.h,
5390	gdbreplay.c, gdbthread.h, hostio-errno.c, hostio.c, i387-fp.c,
5391	inferiors.c, inferiors.h, linux-aarch64-tdesc-selftest.c,
5392	linux-amd64-ipa.c, linux-i386-ipa.c, linux-low.c,
5393	linux-tic6x-low.c, linux-x86-low.c, linux-x86-tdesc-selftest.c,
5394	linux-x86-tdesc.c, lynx-i386-low.c, lynx-low.c, mem-break.h,
5395	nto-x86-low.c, regcache.c, regcache.h, remote-utils.c, server.c,
5396	server.h, spu-low.c, symbol.c, target.h, tdesc.c, tdesc.h,
5397	thread-db.c, tracepoint.c, win32-i386-low.c, win32-low.c: Change
5398	common to gdbsupport.
5399
54002019-07-04  Alan Hayward  <alan.hayward@arm.com>
5401
5402	* linux-aarch32-low.c (arm_read_description, arm_regsets): Use new
5403	defines.
5404	* linux-arm-low.c (arm_read_description, arm_regsets): Likewise.
5405
54062019-07-04  Alan Hayward  <alan.hayward@arm.com>
5407
5408	* configure.srv: Remove legacy xml.
5409	* linux-aarch64-low.c (initialize_low_arch): Remove
5410	initialize_low_tdesc call.
5411	* linux-aarch64-tdesc-selftest.c: Remove file.
5412	* linux-aarch64-tdesc.h (initialize_low_tdesc): Remove.
5413	* linux-x86-low.c (initialize_low_arch): Remove
5414	initialize_low_tdesc call.
5415	* linux-x86-tdesc-selftest.c: Remove file.
5416	* linux-x86-tdesc.h (initialize_low_tdesc): Remove.
5417
54182019-06-20  Tom de Vries  <tdevries@suse.de>
5419
5420	* linux-s390-ipa.c (get_ipa_tdesc)[!__s390x__]: Use
5421	s390_te_linux64_ft_collect_regmap for S390_TDESC_GS.
5422
54232019-06-19  Tom de Vries  <tdevries@suse.de>
5424
5425	* debug.h (debug_write): Change return type to ssize_t.
5426	* debug.c (debug_write): Same.
5427
54282019-06-14  Tom Tromey  <tom@tromey.com>
5429
5430	* configure.ac: Use new path to gnulib.
5431	* configure: Rebuild.
5432	* Makefile.in (INCGNU, $(GNULIB_BUILDDIR)/Makefile): Use new path
5433	to gnulib.
5434
54352019-06-11  Tom Tromey  <tom@tromey.com>
5436
5437	* Makefile.in (SFILES): Add alloc.c.
5438	(OBS): Add alloc.o.
5439	(IPA_OBJS): Add alloc-ipa.o.
5440	(alloc-ipa.o): New target.
5441	(%.o: ../%.c): New pattern rule.
5442
54432019-06-10  Tom Tromey  <tromey@adacore.com>
5444
5445	* remote-utils.c (look_up_one_symbol, relocate_instruction): Don't
5446	end warning with a newline.
5447	* linux-s390-low.c (s390_get_wordsize): Don't end warning with a
5448	newline.
5449	* thread-db.c (attach_thread): Don't end warning with a newline.
5450	(thread_db_notice_clone): Likewise.
5451	* tracepoint.c (gdb_agent_helper_thread): Don't end warning with a
5452	newline.
5453	* linux-x86-low.c (x86_get_min_fast_tracepoint_insn_len): Don't
5454	end warning with a newline.
5455
54562019-06-04  Pedro Alves  <palves@redhat.com>
5457
5458	* server.c (captured_main): Use make_unique_xstrdup.
5459
54602019-06-02  Tom Tromey  <tom@tromey.com>
5461
5462	* gdbreplay.c (fromhex): Remove.
5463	* Makefile.in (GDBREPLAY_OBS): Add rsp-low.o.
5464
54652019-05-29  Tom Tromey  <tromey@adacore.com>
5466
5467	* configure: Rebuild.
5468
54692019-05-06  Kevin Buettner  <kevinb@redhat.com>
5470
5471	* linux-x86-low.c (x86_fill_gregset): Don't compile 64-bit
5472	sign extension code on 32-bit builds.
5473
54742019-05-03  Eli Zaretskii  <eliz@gnu.org>
5475
5476	* remote-utils.c:
5477	* gdbreplay.c [USE_WIN32API]: Remove the _WIN32_WINNT override.
5478
54792019-04-19  Tom Tromey  <tom@tromey.com>
5480
5481	* server.c (struct vstop_notif): Derive from notif_event.
5482	<base>: Remove.
5483	(queue_stop_reply): Update.
5484	(remove_all_on_match_ptid): Change type.  Rewrite.
5485	(discard_queued_stop_replies): Rewrite.
5486	(in_queued_stop_replies_ptid): Change type.
5487	(in_queued_stop_replies): Rewrite.
5488	(notif_stop): Update.
5489	(queue_stop_reply_callback): Update.
5490	(captured_main): Don't call initialize_notif.
5491	(push_stop_notification): Update.
5492	* notif.c (notif_write_event, handle_notif_ack)
5493	(notif_event_enque, notif_push): Update.
5494	(notif_event_xfree, initialize_notif): Remove.
5495	* notif.h (struct notif_event): Include <list>, not
5496	"common/queue.h".
5497	(struct notif_server) <queue>: Now a std::list.
5498	(notif_event_p): Remove typedef.
5499	(initialize_notif): Don't declare.
5500	(struct notif_event): Add virtual destructor.
5501
55022019-04-17  Alan Hayward  <alan.hayward@arm.com>
5503
5504	* ax.c (ax_vdebug): Call debug_printf.
5505	* debug.c (debug_write): New function.
5506	* debug.h (debug_write): New declaration.
5507	* linux-low.c (sigchld_handler): Call debug_write.
5508
55092019-04-17  Alan Hayward  <alan.hayward@arm.com>
5510
5511	* debug.c (debug_set_output): New function.
5512	(debug_vprintf): Send output to debug_file.
5513	(debug_flush): Likewise.
5514	* debug.h (debug_set_output): New declaration.
5515	* server.c (handle_monitor_command): Add debug-file option.
5516	(captured_main): Likewise.
5517
55182019-04-17  Alan Hayward  <alan.hayward@arm.com>
5519
5520	* debug.c (remote_debug): Add definition.
5521	* debug.h (remote_debug): Add declaration.
5522	* hostio.c (remote_debug): Remove declaration.
5523	* remote-utils.c (struct ui_file): Likewise.
5524	(remote_debug): Likewise.
5525	* remote-utils.h (remote_debug): Likewise,
5526	* server.c (remote_debug): Remove definition.
5527
55282019-04-10  Kevin Buettner  <kevinb@redhat.com>
5529
5530	* linux-x86-low.c (x86_fill_gregset): Sign extend EAX value
5531	when using a 64-bit gdbserver.
5532
55332019-04-09  Tom Tromey  <tromey@adacore.com>
5534
5535	* linux-low.c (select_event_lwp): Use find_thread_in_random.
5536
55372019-04-08  Tom Tromey  <tom@tromey.com>
5538
5539	* linux-low.c (linux_detach_one_lwp): Replace throw_exception with
5540	throw.
5541	(linux_resume_one_lwp): Likewise.
5542
55432019-04-08  Tom Tromey  <tom@tromey.com>
5544
5545	* gdbreplay.c: Update.
5546	* linux-low.c: Update.
5547	* server.c: Update.
5548
55492019-04-08  Tom Tromey  <tom@tromey.com>
5550
5551	* server.c: Use C++ exception handling.
5552	* linux-low.c: Use C++ exception handling.
5553	* gdbreplay.c: Use C++ exception handling.
5554
55552019-04-08  Tom Tromey  <tom@tromey.com>
5556
5557	* server.c (handle_btrace_general_set, handle_qxfer_btrace)
5558	(handle_qxfer_btrace_conf, detach_or_kill_for_exit_cleanup)
5559	(captured_main, main): Update.
5560	* gdbreplay.c (main): Update.
5561
55622019-04-05  Pedro Franco de Carvalho  <pedromfc@linux.ibm.com>
5563
5564	* linux-low.c (linux_get_auxv): Remove static.  Return auxv entry
5565	value in argument pointer, return 1 if the entry is found and 0
5566	otherwise.  Move comment.
5567	(linux_get_hwcap, linux_get_hwcap2): Use modified linux_get_auxv.
5568	* linux-low.h (linux_get_auxv): Declare.
5569	* linux-ppc-low.c (is_elfv2_inferior): Use linux_get_auxv.
5570
55712019-04-05  Tom Tromey  <tromey@adacore.com>
5572
5573	* server.c (gdbserver_usage): Use upper-case for metasyntactic
5574	variables.
5575
55762019-03-28  Alan Hayward  <alan.hayward@arm.com>
5577
5578	* linux-low.c (AT_HWCAP2): Add define if not already included.
5579
55802019-03-26  Alan Hayward  <alan.hayward@arm.com>
5581
5582	* linux-aarch64-low.c (aarch64_get_hwcap): Remove function.
5583	(aarch64_arch_setup): Call linux_get_hwcap.
5584	* linux-arm-low.c (arm_get_hwcap): Remove function.
5585	(arm_read_description): Call linux_get_hwcap.
5586	* linux-low.c (linux_get_auxv): New function.
5587	(linux_get_hwcap): Likewise.
5588	(linux_get_hwcap2): Likewise.
5589	* linux-low.h (linux_get_hwcap): New declaration.
5590	(linux_get_hwcap2): Likewise.
5591	* linux-ppc-low.c (ppc_get_auxv): Remove function.
5592	(ppc_arch_setup): Call linux_get_hwcap.
5593	* linux-s390-low.c (s390_get_hwcap): Remove function.
5594	(s390_arch_setup): Call linux_get_hwcap.
5595
55962019-03-22  Alan Hayward  <alan.hayward@arm.com>
5597	    Jiong Wang  <jiong.wang@arm.com>
5598
5599	* linux-aarch64-low.c (aarch64_store_pauthregset): New function.
5600	* linux-low.c (regsets_store_inferior_registers): Allow optional reads
5601	to fail.
5602	* linux-low.h (enum regset_type): Add OPTIONAL_REGS.
5603
56042019-03-22  Alan Hayward  <alan.hayward@arm.com>
5605	    Jiong Wang  <jiong.wang@arm.com>
5606
5607	* linux-aarch64-low.c (AARCH64_HWCAP_PACA): New define.
5608	(aarch64_get_hwcap): New function.
5609	(aarch64_arch_setup): Read APIA hwcap.
5610
56112019-03-22  Alan Hayward  <alan.hayward@arm.com>
5612	    Jiong Wang  <jiong.wang@arm.com>
5613
5614	* linux-aarch64-ipa.c (get_ipa_tdesc): Add pauth param.
5615	(initialize_low_tracepoint): Likewise.
5616	* linux-aarch64-low.c (aarch64_arch_setup): Likewise.
5617	* linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Likewise.
5618	* linux-aarch64-tdesc.c (struct target_desc): Likewise.
5619	(aarch64_linux_read_description): Likewise.
5620	* linux-aarch64-tdesc.h (aarch64_linux_read_description): Likewise.
5621
56222019-03-12  John Baldwin  <jhb@FreeBSD.org>
5623
5624	* linux-x86-tdesc.c (i386_linux_read_description): Update call to
5625	i386_create_target_description for 'segments' parameter.
5626	* lynx-i386-low.c (lynx_i386_arch_setup): Likewise.
5627	* nto-x86-low.c (nto_x86_arch_setup): Likewise.
5628	* win32-i386-low.c (i386_arch_setup): Likewise.
5629
56302019-03-12  Tom Tromey  <tromey@adacore.com>
5631
5632	* linux-low.c (iterate_over_lwps): Update.
5633
56342019-03-06  Tom Tromey  <tom@tromey.com>
5635
5636	* server.c (detach_or_kill_for_exit_cleanup): Remove parameter.
5637	(captured_main): Use SCOPE_EXIT.
5638
56392019-03-04  Sergio Durigan Junior  <sergiodj@redhat.com>
5640
5641	* configure.srv: Use '$enable_unittest' instead of '$development'
5642	when checking whether to fill 'srv_regobj' on 'aarch64*-*-linux*'
5643	case.
5644
56452019-02-27  Tom Tromey  <tromey@adacore.com>
5646
5647	* gdbreplay.c (logchar): Handle \r\n.
5648
56492019-02-07  Alan Hayward  <alan.hayward@arm.com>
5650
5651	* linux-low.c (linux_attach): Add process before lwp.
5652	* server.c (attach_inferior): Check if already attached.
5653
56542019-02-07  Tom Tromey  <tom@tromey.com>
5655
5656	* x86-tdesc.h: Rename include guard.
5657	* x86-low.h: Add include guard.
5658	* wincecompat.h: Rename include guard.
5659	* win32-low.h: Add include guard.
5660	* utils.h: Rename include guard.
5661	* tracepoint.h: Rename include guard.
5662	* tdesc.h: Rename include guard.
5663	* target.h: Rename include guard.
5664	* server.h: Rename include guard.
5665	* remote-utils.h: Rename include guard.
5666	* regcache.h: Rename include guard.
5667	* nto-low.h: Rename include guard.
5668	* notif.h: Add include guard.
5669	* mem-break.h: Rename include guard.
5670	* lynx-low.h: Add include guard.
5671	* linux-x86-tdesc.h: Add include guard.
5672	* linux-s390-tdesc.h: Add include guard.
5673	* linux-ppc-tdesc-init.h: Add include guard.
5674	* linux-low.h: Add include guard.
5675	* linux-aarch64-tdesc.h: Add include guard.
5676	* linux-aarch32-low.h: Add include guard.
5677	* inferiors.h: Rename include guard.
5678	* i387-fp.h: Rename include guard.
5679	* hostio.h: Rename include guard.
5680	* gdbthread.h: Rename include guard.
5681	* gdb_proc_service.h: Rename include guard.
5682	* event-loop.h: Rename include guard.
5683	* dll.h: Rename include guard.
5684	* debug.h: Rename include guard.
5685	* ax.h: Rename include guard.
5686
56872018-01-30  Szabolcs Nagy  <szabolcs.nagy@arm.com>
5688
5689	PR gdb/23985
5690	* Makefile.in (IPAGENT_CFLAGS): Add UNDO_GNULIB_CFLAGS.
5691	(UNDO_GNULIB_CFLAGS): Undo gnulib replacements.
5692
56932019-01-25  Tom Tromey  <tom@tromey.com>
5694
5695	* Makefile.in (INCLUDE_CFLAGS): Don't add -I for common.
5696
56972019-01-25  Tom Tromey  <tom@tromey.com>
5698
5699	* win32-low.c: Fix common/ includes.
5700	* win32-i386-low.c: Fix common/ includes.
5701	* tracepoint.c: Fix common/ includes.
5702	* thread-db.c: Fix common/ includes.
5703	* target.h: Fix common/ includes.
5704	* symbol.c: Fix common/ includes.
5705	* spu-low.c: Fix common/ includes.
5706	* server.h: Fix common/ includes.
5707	* server.c: Fix common/ includes.
5708	* remote-utils.c: Fix common/ includes.
5709	* regcache.h: Fix common/ includes.
5710	* regcache.c: Fix common/ includes.
5711	* nto-x86-low.c: Fix common/ includes.
5712	* notif.h: Fix common/ includes.
5713	* mem-break.h: Fix common/ includes.
5714	* lynx-low.c: Fix common/ includes.
5715	* lynx-i386-low.c: Fix common/ includes.
5716	* linux-x86-tdesc-selftest.c: Fix common/ includes.
5717	* linux-x86-low.c: Fix common/ includes.
5718	* linux-low.c: Fix common/ includes.
5719	* inferiors.h: Fix common/ includes.
5720	* i387-fp.c: Fix common/ includes.
5721	* hostio.c: Fix common/ includes.
5722	* hostio-errno.c: Fix common/ includes.
5723	* gdbthread.h: Fix common/ includes.
5724	* gdbreplay.c: Fix common/ includes.
5725	* fork-child.c: Fix common/ includes.
5726	* event-loop.c: Fix common/ includes.
5727	* ax.c (enum gdb_agent_op): Fix common/ includes.
5728
57292019-01-21  Tom Tromey  <tom@tromey.com>
5730
5731	* tracepoint.c: Fix includes.
5732	* remote-utils.c: Fix includes.
5733	* linux-x86-low.c: Fix includes.
5734
57352019-01-01  Joel Brobecker  <brobecker@adacore.com>
5736
5737	* gdbreplay.c (gdbreplay_version): Update copyright year in
5738	version message.
5739	* server.c (gdbserver_version): Likewise.
5740
57412018-12-05  Alan Hayward  <alan.hayward@arm.com>
5742
5743	* linux-low.c (add_lwp): Switch ordering.
5744
57452018-11-29  Tom Tromey  <tom@tromey.com>
5746
5747	* win32-low.c (win32_join): Take pid, not process.
5748	* target.h (struct target_ops) <join>: Change argument type.
5749	(join_inferior): Change argument name.
5750	* spu-low.c (spu_join): Take pid, not process.
5751	* server.c (handle_detach): Preserve pid before destroying
5752	process.
5753	* lynx-low.c (lynx_join): Take pid, not process.
5754	* linux-low.c (linux_join): Take pid, not process.
5755
57562018-11-23  Alan Hayward  <alan.hayward@arm.com>
5757
5758	* linux-aarch64-low.c (aarch64_cannot_store_register): Remove.
5759	(aarch64_cannot_fetch_register): Likewise.
5760	(struct linux_target_ops): Update references.
5761
57622018-10-31  Pedro Franco de Carvalho  <pedromfc@linux.ibm.com>
5763
5764	* linux-ppc-low.c: Include nat/linux-ptrace.h.
5765
57662018-10-26  Pedro Franco de Carvalho  <pedromfc@linux.ibm.com>
5767
5768	* configure.srv (ipa_ppc_linux_regobj): Add
5769	powerpc-isa207-htm-vsx32l-ipa.o and
5770	powerpc-isa207-htm-vsx64l-ipa.o.
5771	(powerpc*-*-linux*): Add powerpc-isa207-htm-vsx32l.o and
5772	powerpc-isa207-htm-vsx64l.o to srv_regobj.  Add
5773	rs6000/power-htm-spr.xml, rs6000/power-htm-core.xml,
5774	rs6000/power64-htm-core.xml, rs6000/power-htm-fpu.xml,
5775	rs6000/power-htm-altivec.xml, rs6000/power-htm-vsx.xml,
5776	rs6000/power-htm-ppr.xml, rs6000/power-htm-dscr.xml,
5777	rs6000/power-htm-tar.xml, rs6000/powerpc-isa207-htm-vsx32l.xml,
5778	and rs6000/powerpc-isa207-htm-vsx64l.xml to srv_xmlfiles.
5779	* linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
5780	<PPC_TDESC_ISA207_HTM_VSX>: New enum value.
5781	(init_registers_powerpc_isa207_htm_vsx32l)
5782	(init_registers_powerpc_isa207_htm_vsx64l): Declare.
5783	* linux-ppc-low.c (ppc_fill_tm_sprregset, ppc_store_tm_sprregset)
5784	(ppc_store_tm_cgprregset, ppc_store_tm_cfprregset)
5785	(ppc_store_tm_cvrregset, ppc_store_tm_cvsxregset)
5786	(ppc_store_tm_cpprregset, ppc_store_tm_cdscrregset)
5787	(ppc_store_tm_ctarregset): New functions.
5788	(ppc_regsets): Add entries for HTM regsets.
5789	(ppc_arch_setup): Set htm in features struct when needed.  Set
5790	sizes for the HTM regsets.
5791	(ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_HTM_VSX.
5792	(initialize_low_arch): Call
5793	init_registers_powerpc_isa207_htm_vsx32l and
5794	init_registers_powerpc_isa207_htm_vsx64l.
5795	* linux-ppc-ipa.c (get_ipa_tdesc): Handle
5796	PPC_TDESC_ISA207_HTM_VSX.
5797	(initialize_low_tracepoint): Call
5798	init_registers_powerpc_isa207_htm_vsx32l and
5799	init_registers_powerpc_isa207_htm_vsx64l.
5800
58012018-10-26  Pedro Franco de Carvalho  <pedromfc@linux.ibm.com>
5802
5803	* configure.srv (powerpc*-*-linux*): Add rs6000/power-ebb.xml and
5804	rs6000/power-linux-pmu.xml to srv_xmlfiles.
5805	* linux-ppc-low.c (ppc_store_ebbregset, ppc_fill_pmuregset)
5806	(ppc_store_pmuregset): New functions.
5807	(ppc_regsets): Add entries for ebb and pmu regsets.
5808	(ppc_arch_setup): Set isa207 in features struct if the ebb and
5809	pmu regsets are available.  Set sizes for these regsets.
5810
58112018-10-26  Pedro Franco de Carvalho  <pedromfc@linux.ibm.com>
5812
5813	* configure.srv (ipa_ppc_linux_regobj): Add
5814	powerpc-isa207-vsx64l-ipa.o and powerpc-isa207-vsx32l-ipa.o.
5815	(powerpc*-*-linux*): Add powerpc-isa207-vsx32l.o and
5816	powerpc-isa207-vsx64l.o to srv_regobj, add rs6000/power-tar.xml,
5817	rs6000/powerpc-isa207-vsx32l.xml, and
5818	rs6000/powerpc-isa207-vsx64l.xml to srv_xmlfiles.
5819	* linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
5820	<PPC_TDESC_ISA207_VSX>: New enum value.
5821	(init_registers_powerpc_isa207_vsx32l): Declare.
5822	(init_registers_powerpc_isa207_vsx64l): Declare.
5823	* linux-ppc-low.c (ppc_fill_tarregset): New function.
5824	(ppc_store_tarregset): New function.
5825	(ppc_regsets): Add entry for the TAR regset.
5826	(ppc_arch_setup): Set isa207 in features struct when needed.  Set
5827	size for the TAR regsets.
5828	(ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_VSX.
5829	(initialize_low_arch): Call init_registers_powerpc_isa207_vsx32l
5830	and init_registers_powerpc_isa207_vsx64l.
5831	* linux-ppc-ipa.c (get_ipa_tdesc): Handle PPC_TDESC_ISA207_VSX.
5832	(initialize_low_tracepoint): Call
5833	init_registers_powerpc_isa207_vsx32l and
5834	init_registers_powerpc_isa207_vsx64l.
5835
58362018-10-26  Edjunior Barbosa Machado  <emachado@linux.vnet.ibm.com>
5837	    Pedro Franco de Carvalho  <pedromfc@linux.ibm.com>
5838
5839	* configure.srv (ipa_ppc_linux_regobj): Add
5840	powerpc-isa205-ppr-dscr-vsx32l-ipa.o and
5841	powerpc-isa205-ppr-dscr-vsx64l-ipa.o.
5842	(powerpc*-*-linux*): Add powerpc-isa205-ppr-dscr-vsx32l.o and
5843	powerpc-isa205-ppr-dscr-vsx64l.o to srv_regobj, add
5844	rs6000/power-dscr.xml, rs6000/power-ppr.xml,
5845	rs6000/powerpc-isa205-ppr-dscr-vsx32l.xml and
5846	rs6000/powerpc-isa205-ppr-dscr-vsx64l.xml to srv_xmlfiles.
5847	* linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
5848	<PPC_TDESC_ISA205_PPR_DSCR_VSX>: New enum value.
5849	(init_registers_powerpc_isa205_ppr_dscr_vsx32l)
5850	(init_registers_powerpc_isa205_ppr_dscr_vsx64l): Declare.
5851	* linux-ppc-low.c: Include "elf/common.h" and <sys/uio.h>.
5852	(ppc_hwcap): Add comment.
5853	(ppc_hwcap2): New global.
5854	(ppc_check_regset, ppc_fill_pprregset, ppc_store_pprregset)
5855	(ppc_fill_dscrregset, ppc_store_dscrregset): New functions.
5856	(ppc_regsets): Add entries for the DSCR and PPR regsets.
5857	(ppc_arch_setup): Get AT_HWCAP2.  Set ppr_dscr in features struct
5858	when needed.  Set sizes for the the DSCR and PPR regsets.
5859	(ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA205_PPR_DSCR_VSX.
5860	(initialize_low_arch): Call
5861	init_registers_powerpc_isa205_ppr_dscr_vsx32l and
5862	init_registers_powerpc_isa205_ppr_dscr_vsx64l.
5863	* linux-ppc-ipa.c (get_ipa_tdesc): Handle
5864	PPC_TDESC_ISA205_PPR_DSCR_VSX.
5865	(initialize_low_tracepoint): Call
5866	init_registers_powerpc_isa205_ppr_dscr_vsx32l and
5867	init_registers_powerpc_isa205_ppr_dscr_vsx64l.
5868
58692018-10-26  Pedro Franco de Carvalho  <pedromfc@linux.ibm.com>
5870
5871	* linux-ppc-low.c (ppc_fill_vrregset): Remove memset calls.
5872
58732018-10-10  Sergio Durigan Junior  <sergiodj@redhat.com>
5874	    Simon Marchi <simark@simark.ca>
5875
5876	* acinclude.m4: Include "../selftest.m4".
5877	* configure: Regenerate.
5878	* configure.ac: Use "GDB_AC_SELFTEST".
5879	* configure.srv: Use "$enable_unittests" instead of
5880	"$development" when checking whether unit tests have been
5881	enabled.
5882	* server.c (captured_main): Update message informing that
5883	selftests have been disabled.
5884
58852018-10-04  Tom Tromey  <tom@tromey.com>
5886
5887	* configure: Rebuild.
5888
58892018-10-04  Tom Tromey  <tom@tromey.com>
5890
5891	* server.c (handle_status): Rename inner "thread".
5892	(process_serial_event): Declare "res" in 'm' case.
5893	* linux-low.c (last_thread_of_process_p, find_lwp_pid)
5894	(iterate_over_lwps): Rename inner "thread".
5895	(linux_qxfer_libraries_svr4): Rename inner "len".
5896	* gdbthread.h (find_thread_in_random): Rename inner "thread".
5897
58982018-10-01  Gary Benson <gbenson@redhat.com>
5899
5900	* gdb_proc_service.h: Moved common code to
5901	common/gdb_proc_service.h.
5902
59032018-10-01  Gary Benson <gbenson@redhat.com>
5904
5905	* gdb_proc_service.h: Synchronize comments and whitespace with
5906	GDB's version of this file.
5907
59082018-09-25  Tom Tromey  <tom@tromey.com>
5909
5910	* configure: Rebuild.
5911	* configure.ac (WARN_CFLAGS): Don't remove -Wmissing-prototypes.
5912
59132018-09-16  Simon Marchi  <simon.marchi@polymtl.ca>
5914
5915	* Makefile.in (gdbserver$(EXEEXT)): Sort OBS.
5916	(gdbreplay$(EXEEXT)): Sort GDBREPLAY_OBS.
5917	($(IPA_LIB)): Sort IPA_OBJS.
5918
59192018-09-16  Simon Marchi  <simon.marchi@polymtl.ca>
5920
5921	* Makefile.in: Remove references to $(ADD_DEPS).
5922
59232018-09-16  Tom Tromey  <tom@tromey.com>
5924
5925	* remote-utils.c (remote_open): Use GNU style for metasyntactic
5926	variables.
5927	* gdbreplay.c (gdbreplay_usage): Use GNU style for metasyntactic
5928	variables.
5929
59302018-09-05  Tom Tromey  <tom@tromey.com>
5931
5932	* configure: Rebuild.
5933
59342018-08-28  Simon Marchi  <simon.marchi@polymtl.ca>
5935
5936	PR build/23399
5937	* tracepoint.c (IPA_SYM_STRUCT_NAME): Define.
5938
59392018-08-27  Tom Tromey  <tom@tromey.com>
5940
5941	PR build/23087:
5942	* configure: Rebuild.
5943
59442018-08-27  Tom Tromey  <tom@tromey.com>
5945
5946	* linux-s390-low.c (s390_emit_ext, s390_emit_litpool)
5947	(s390_emit_const, s390_emit_reg, s390_emit_zero_ext)
5948	(s390_emit_stack_adjust, s390_emit_set_r2, s390x_emit_ext)
5949	(s390x_emit_const, s390x_emit_reg, s390x_emit_zero_ext)
5950	(s390x_emit_stack_adjust): Add casts to unsigned char.
5951
59522018-08-22  Simon Marchi  <simon.marchi@ericsson.com>
5953
5954	PR gdb/23374
5955	PR gdb/23375
5956	* server.h (struct client_state) <disable_randomization>:
5957	Initialize to 1.
5958
59592018-07-22  Simon Marchi  <simon.marchi@polymtl.ca>
5960
5961	* linux-mips-low.c (mips_collect_ptrace_register): Remove unused
5962	variable.
5963	(mips_supply_ptrace_register): Likewise.
5964
59652018-07-22  Tom Tromey  <tom@tromey.com>
5966
5967	* configure: Rebuild.
5968
59692018-07-22  Tom Tromey  <tom@tromey.com>
5970
5971	* win32-low.c (win32_create_inferior): Remove unused variables.
5972	* gdbreplay.c (remote_open): Remove unused variable.
5973	* remote-utils.c (remote_prepare): Remove unused variable.
5974	* x86-tdesc.h (X86_TDESC_H): Define.
5975	(amd64_expedite_regs): Define conditionally.
5976	(i386_expedite_regs): Mark ATTRIBUTE_UNUSED.
5977	* linux-x86-tdesc.c (i386_tdescs): Move inside #if.
5978	* remote-utils.c (readchar): Remove unused variable.
5979
59802018-07-13  Pedro Alves  <palves@redhat.com>
5981
5982	* linux-low.c (linux_kill): Change parameter to process_info
5983	pointer instead of pid.  Adjust.
5984	* lynx-low.c (lynx_kill): Likewise.
5985	* nto-low.c (nto_kill): Likewise.
5986	* spu-low.c (spu_kill): Likewise.
5987	* win32-low.c (win32_kill): Likewise.
5988	* server.c (handle_v_kill, kill_inferior_callback)
5989	(detach_or_kill_for_exit): Adjust.
5990	* target.c (kill_inferior): Change parameter to process_info
5991	pointer instead of pid.  Adjust.
5992	* target.h (struct target_ops) <kill>: Change parameter to
5993	process_info pointer instead of pid.  Adjust all implementations
5994	and callers.
5995	(kill_inferior): Likewise.
5996
59972018-07-13  Pedro Alves  <palves@redhat.com>
5998
5999	* linux-low.c (linux_detach, linux_join): Change parameter to
6000	process_info pointer instead of pid.  Adjust.
6001	* lynx-low.c (lynx_detach, lynx_join): Likewise.
6002	* nto-low.c (nto_detach): Likewise.
6003	* spu-low.c (spu_detach, spu_join): Likewise.
6004	* win32-low.c (win32_detach, win32_join): Likewise.
6005	* server.c (handle_detach, detach_or_kill_for_exit): Adjust.
6006	* target.h (struct target_ops) <detach, join>: Change parameter to
6007	process_info pointer instead of pid.  Adjust all implementations
6008	and callers.
6009	(detach_inferior, join_inferior): Rename 'pid' parameter to
6010	'proc'.
6011
60122018-07-11  Sergio Durigan Junior  <sergiodj@redhat.com>
6013	    Jan Kratochvil  <jan.kratochvil@redhat.com>
6014	    Paul Fertser  <fercerpav@gmail.com>
6015	    Tsutomu Seki  <sekiriki@gmail.com>
6016
6017	* Makefile.in (SFILES): Add '$(srcdir)/common/netstuff.c'.
6018	(OBS): Add 'common/netstuff.o'.
6019	(GDBREPLAY_OBS): Likewise.
6020	* gdbreplay.c: Include 'wspiapi.h' and 'netstuff.h'.
6021	(remote_open): Implement support for IPv6
6022	connections.
6023	* remote-utils.c: Include 'netstuff.h', 'filestuff.h'
6024	and 'wspiapi.h'.
6025	(handle_accept_event): Accept connections from IPv6 sources.
6026	(remote_prepare): Handle IPv6-style hostnames; implement
6027	support for IPv6 connections.
6028	(remote_open): Implement support for printing connections from
6029	IPv6 sources.
6030
60312018-07-11  Pedro Alves  <palves@redhat.com>
6032
6033	PR gdb/23377
6034	* mem-break.c (any_persistent_commands): Add process_info
6035	parameter and use it instead of relying on the current process.
6036	Change return type to bool.
6037	* mem-break.h (any_persistent_commands): Add process_info
6038	parameter and change return type to bool.
6039	* server.c (handle_detach): Remove require_running_or_return call.
6040	Look up the process_info for the process we're about to detach.
6041	If not found, return back error to GDB.  Adjust
6042	any_persistent_commands call to pass down a process pointer.
6043
60442018-07-11  Pedro Alves  <palves@redhat.com>
6045
6046	* i387-fp.c (i387_cache_to_fsave, cache_to_fxsave)
6047	(i387_cache_to_xsave): Use regcache_raw_get_unsigned_by_name
6048	instead of collect_register_by_name.
6049	* regcache.c (regcache_raw_get_unsigned_by_name): New.
6050	* regcache.h (regcache_raw_get_unsigned_by_name): New.
6051
60522018-07-04  Vyacheslav Barinov  <v.barinov@samsung.com>
6053	    Pedro Alves  <palves@redhat.com>
6054
6055	* linux-low.c (initialize_low): Call linux_proc_init_warnings.
6056
60572018-07-03  Tom Tromey  <tom@tromey.com>
6058
6059	* linux-low.c: Update.
6060	* lynx-low.c: Update.
6061	* mem-break.c: Update.
6062	* nto-low.c: Update.
6063	* remote-utils.c: Update.
6064	* server.c: Update.
6065	* spu-low.c: Update.
6066	* target.c: Update.
6067	* win32-low.c: Update.
6068
60692018-07-03  Tom Tromey  <tom@tromey.com>
6070
6071	* server.c: Update.
6072
60732018-07-03  Tom Tromey  <tom@tromey.com>
6074
6075	* linux-low.c: Update.
6076
60772018-07-03  Tom Tromey  <tom@tromey.com>
6078
6079	* target.c: Update.
6080
60812018-07-03  Tom Tromey  <tom@tromey.com>
6082
6083	* linux-low.c: Update.
6084	* linux-mips-low.c: Update.
6085	* lynx-low.c: Update.
6086	* nto-low.c: Update.
6087	* remote-utils.c: Update.
6088	* server.c: Update.
6089	* spu-low.c: Update.
6090	* target.c: Update.
6091	* thread-db.c: Update.
6092
60932018-07-03  Tom Tromey  <tom@tromey.com>
6094
6095	* linux-low.c: Update.
6096	* linux-mips-low.c: Update.
6097	* lynx-low.c: Update.
6098	* mem-break.c: Update.
6099	* nto-low.c: Update.
6100	* remote-utils.c: Update.
6101	* server.c: Update.
6102	* spu-low.c: Update.
6103	* target.c: Update.
6104	* tracepoint.c: Update.
6105
61062018-07-03  Tom Tromey  <tom@tromey.com>
6107
6108	* linux-low.c: Update.
6109	* linux-ppc-low.c: Update.
6110	* linux-x86-low.c: Update.
6111	* proc-service.c: Update.
6112	* server.c: Update.
6113	* spu-low.c: Update.
6114	* thread-db.c: Update.
6115	* win32-low.c: Update.
6116
61172018-07-03  Tom Tromey  <tom@tromey.com>
6118
6119	* linux-low.c: Update.
6120	* lynx-low.c: Update.
6121	* nto-low.c: Update.
6122	* remote-utils.c: Update.
6123	* spu-low.c: Update.
6124	* thread-db.c: Update.
6125	* win32-low.c: Update.
6126
61272018-06-29  Joel Brobecker  <brobecker@adacore.com>
6128
6129	* linux-x86-tdesc.c (amd64_linux_read_description): Add missing
6130	parameter in call to 'amd64_create_target_description'.
6131
61322018-06-28  Jan Kratochvil  <jan.kratochvil@redhat.com>
6133
6134	* x86-tdesc.h: Remove executable permission flag.
6135
61362018-06-19  Simon Marchi  <simon.marchi@ericsson.com>
6137
6138	* configure.ac: Remove AC_PREREQ, add missing quoting.
6139	* configure: Re-generate.
6140	* config.in: Re-generate.
6141	* aclocal.m4: Re-generate.
6142
61432018-06-18  Simon Marchi  <simon.marchi@ericsson.com>
6144
6145	* tracepoint.h (current_traceframe): Remove declaration.
6146
61472018-06-18  Alan Hayward  <alan.hayward@arm.com>
6148
6149	* linux-aarch64-low.c (is_sve_tdesc): New function.
6150	(aarch64_sve_regs_copy_to_regcache): Likewise.
6151	(aarch64_sve_regs_copy_from_regcache): Likewise.
6152	(aarch64_regs_info): Add SVE checks.
6153	(initialize_low_arch): Initialize SVE.
6154
61552018-06-18  Alan Hayward  <alan.hayward@arm.com>
6156
6157	* Makefile.in: Add aarch64-sve-linux-ptrace.c.
6158
61592018-06-11  Alan Hayward  <alan.hayward@arm.com>
6160
6161	* linux-aarch64-ipa.c (get_ipa_tdesc): Add null VQ param.
6162	(initialize_low_tracepoint): Likewise
6163	* linux-aarch64-low.c (aarch64_arch_setup): Get VQ.
6164	* linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Add null VQ
6165	param.
6166	* linux-aarch64-tdesc.c (aarch64_linux_read_description): Add VQ
6167	checks.
6168	* linux-aarch64-tdesc.h (aarch64_linux_read_description): Add VQ.
6169
61702018-06-11  Alan Hayward  <alan.hayward@arm.com>
6171
6172	* server.h (PBUFSIZ): Increase size
6173
61742018-06-11  Alan Hayward  <alan.hayward@arm.com>
6175
6176	* regcache.c (regcache::raw_compare): New function.
6177	* regcache.h (regcache::raw_compare): New declaration.
6178
61792018-06-11  Alan Hayward  <alan.hayward@arm.com>
6180
6181	* regcache.c (new_register_cache): Use new.
6182	(free_register_cache): Use delete.
6183	(register_data): Use const.
6184	(supply_register): Move body inside regcache.
6185	(regcache::raw_supply): New override function.
6186	(collect_register): Move body inside regcache.
6187	(regcache::raw_collect): New override function.
6188	(regcache::get_register_status): New override function.
6189	* regcache.h (struct regcache): Inherit from reg_buffer_common.
6190
61912018-06-09  Tom Tromey  <tom@tromey.com>
6192
6193	* event-loop.c (gdb_event, gdb_event_p): Remove typedefs.  Don't
6194	declare queue.
6195	(event_queue): Use std::queue.
6196	(gdb_event_xfree): Remove.
6197	(initialize_event_loop, process_event, wait_for_event): Update.
6198
61992018-06-08  Stan Cox  <scox@redhat.com>
6200
6201	* win32-low.c (win32_create_inferior):  last_ptid and last_status
6202	moved to client_state.
6203
62042018-06-08  Pedro Alves  <palves@redhat.com>
6205
6206	* Makefile.in (GDBREPLAY_OBS): Add common/cleanups.o,
6207	common/common-exceptions.o, common/common-utils.o,
6208	common/errors.o, common/print-utils.o and utils.o.
6209	* gdbreplay.c: Include "common-defs.h" instead of the two
6210	'config.h's here.  Don't include stdio.h, errno.h, stdlib.h,
6211	string.h or alloca.h.
6212	(perror_with_name): Delete.
6213	(remote_open): Use xstrdup instead of strdup.
6214	(main): Rename to ...
6215	(captured_main): ... this.
6216	(main): New.
6217
62182018-06-08  Tom Tromey  <tom@tromey.com>
6219
6220	* linux-low.c (linux_low_read_btrace): Update.
6221
62222018-06-04  Stan Cox  <scox@redhat.com>
6223
6224	* server.h (struct client_state): New.
6225	* server.c (cont_thread, general_thread, multi_process)
6226	(report_fork_events, report_vfork_events, report_exec_events)
6227	(report_thread_events, swbreak_feature, hwbreak_feature)
6228	(vCont_supported, disable_randomization, pass_signals)
6229	(program_signals, program_signals_p, last_status, last_ptid, own_buf):
6230	Moved to client_state.
6231	* remote-utils.c (remote_debug, noack_mode)
6232	(transport_is_reliable): Moved to client_state.
6233	* tracepoint.c (current_traceframe): Moved to client_state.
6234
6235	Update all callers.
6236	* server.c, remote-utils.c, tracepoint.c, fork-child.c,
6237	linux-low.c, remote-utils.h, target.c: Use client_state.
6238
62392018-05-31  Alan Hayward  <alan.hayward@arm.com>
6240
6241	* configure.srv: Add new c/h file.
6242
62432018-05-31  Alan Hayward  <alan.hayward@arm.com>
6244
6245	* linux-aarch64-tdesc.c (aarch64_linux_read_description): Add
6246	null VQ.
6247
62482018-05-25  Maciej W. Rozycki  <macro@mips.com>
6249
6250	* gdb.arch/mips-fpregset-core.exp: New test.
6251	* gdb.arch/mips-fpregset-core.c: New test source.
6252
62532018-05-23  Erik Kurzinger  <ekurzinger@nvidia.com>
6254
6255	PR server/23198
6256	* hostio.c (require_int): Do not report overflow for integers
6257	between 0xfffffff and 0x7fffffff.
6258
62592018-05-22  Maciej W. Rozycki  <macro@mips.com>
6260
6261	* linux-mips-low.c [HAVE_PTRACE_GETREGS] (mips_collect_register)
6262	(mips_supply_register): Move outside HAVE_PTRACE_GETREGS.
6263	(mips_collect_ptrace_register, mips_supply_ptrace_register): New
6264	functions.
6265	(the_low_target): Wire them.
6266
62672018-05-22  Pedro Franco de Carvalho  <pedromfc@linux.vnet.ibm.com>
6268
6269	* linux-ppc-low.c (ppc_fill_vrregset): Add vscr_offset variable.
6270	Set vscr_offset to 0 in little-endian mode and 12 in big-endian
6271	mode. Call collect_register_by_name with vscr using
6272	vscr_offset. Zero-pad vscr and vrsave fields in collector buffer.
6273	(ppc_store_vrregset): Add and set vscr_offset variable as in
6274	ppc_fill_vrregset. Call supply_register_by_name with vscr using
6275	vscr_offset.
6276
62772018-05-22  Pedro Franco de Carvalho  <pedromfc@linux.vnet.ibm.com>
6278
6279	* linux-ppc-low.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
6280	(ppc_arch_setup): Change SIZEOF_VRREGS and SIZEOF_VSXREGS to
6281	PPC_LINUX_SIZEOF_VRREGSET and PPC_LINUX_SIZEOF_VSXREGSET.
6282
62832018-05-22  Pedro Franco de Carvalho  <pedromfc@linux.vnet.ibm.com>
6284
6285	* linux-ppc-low.c (ppc_fill_vsxregset): Remove ppc_hwcap check.
6286	(ppc_store_vsxregset): Likewise.
6287	(ppc_fill_vrregset): Likewise.
6288	(ppc_store_vrregset): Likewise.
6289	(ppc_fill_evrregset): Likewise.
6290	(ppc_store_evrregset): Likewise.
6291	(ppc_regsets): Set VSX/VR/EVR regset sizes to 0.
6292	(ppc_arch_setup): Iterate through ppc_regsets and set sizes when
6293	needed.
6294
62952018-05-22  Pedro Franco de Carvalho  <pedromfc@linux.vnet.ibm.com>
6296
6297	* linux-ppc-low.c (ppc_arch_setup): Remove code for getting the
6298	wordsize of the inferior. Call ppc_linux_target_wordsize.
6299
63002018-05-22  Pedro Franco de Carvalho  <pedromfc@linux.vnet.ibm.com>
6301
6302	* configure.srv (srv_tgtobj): Add arch/ppc-linux-common.o.
6303	* Makefile.in (SFILES): Add arch/ppc-linux-common.c.
6304	* linux-ppc-tdesc.h: Rename to linux-ppc-tdesc-init.h.
6305	* linux-ppc-tdesc-init.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
6306	(tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
6307	(tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
6308	(tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
6309	(tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
6310	(tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
6311	(tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
6312	(tdesc_powerpc_e500l): Remove.
6313	* linux-ppc-ipa.c: Include arch/ppc-linux-tdesc.h and
6314	linux-ppc-tdesc-init.h. Don't include linux-ppc-tdesc.h.
6315	* linux-ppc-low.c: Include arch/ppc-linux-common.h,
6316	arch/ppc-linux-tdesc.h, and linux-ppc-tdesc-init.h. Don't include
6317	linux-ppc-tdesc.h.
6318	(ppc_arch_setup): Remove target description matching code. Fill a
6319	ppc_linux_features struct and call ppc_linux_match_description
6320	with it.
6321
63222018-05-22  Maciej W. Rozycki  <macro@mips.com>
6323
6324	* linux-mips-low.c (mips_cannot_fetch_register): Return 1 if the
6325	width of the requested register exceeds the width of the
6326	`ptrace' data type.
6327	(mips_cannot_store_register): Likewise.
6328
63292018-05-21  Maciej W. Rozycki  <macro@mips.com>
6330
6331	* linux-mips-low.c (mips_fetch_register): New function.  Update
6332	preceding comment.
6333	(mips_store_gregset): Supply 0 rather than $restart for $zero.
6334	(the_low_target): Wire `mips_fetch_register'.
6335
63362018-05-10  Joel Brobecker  <brobecker@adacore.com>
6337
6338	* lynx-i386-low.c (LYNXOS_178): New macro.
6339	[LYNXOS_178] (usr_fcontext_t): Provide a definition that matches
6340	the layout on LynxOS-178.
6341	(lynx_i386_fill_fpregset, lynx_i386_store_fpregset): Do not
6342	handle floating point registers that are not supported by
6343	LynxOS-178.
6344
63452018-05-10  Tom Tromey  <tom@tromey.com>
6346
6347	* configure: Rebuild.
6348
63492018-05-10  Joel Brobecker  <brobecker@adacore.com>
6350
6351	PR server/23158:
6352	* tdesc.h (init_target_desc) <expedite_regs>: New parameter.
6353	* tdesc.c (init_target_desc) <expedite_regs>: New parameter.
6354	Use it to set the expedite_regs field in the given tdesc.
6355	* x86-tdesc.h: New file.
6356	* linux-aarch64-tdesc.c (aarch64_linux_read_description):
6357	Adjust following the addition of the new expedite_regs parameter
6358	to init_target_desc.
6359	* linux-tic6x-low.c (tic6x_read_description): Likewise.
6360	* linux-x86-tdesc.c: #include "x86-tdesc.h".
6361	(i386_linux_read_description, amd64_linux_read_description):
6362	Adjust following the addition of the new expedite_regs parameter
6363	to init_target_desc.
6364	* lynx-i386-low.c: #include "x86-tdesc.h".
6365	(lynx_i386_arch_setup): Adjust following the addition of the new
6366	expedite_regs parameter to init_target_desc.
6367	* nto-x86-low.c: #include "x86-tdesc.h".
6368	(nto_x86_arch_setup): Adjust following the addition of the new
6369	expedite_regs parameter to init_target_desc.
6370	* win32-i386-low.c: #include "x86-tdesc.h".
6371	(i386_arch_setup): Adjust following the addition of the new
6372	expedite_regs parameter to init_target_desc.
6373
63742018-05-10  Joel Brobecker  <brobecker@adacore.com>
6375
6376	PR server/23158:
6377	* win32-low.c (win32_create_inferior): Add call to my_wait
6378	setting last_status global.
6379
63802018-05-10  Joel Brobecker  <brobecker@adacore.com>
6381
6382	PR server/23158:
6383	* win32-low.c (create_process): Only call gdb_tilde_expand if
6384	inferior_cwd is not NULL.
6385
63862018-05-08  Andrew Burgess  <andrew.burgess@embecosm.com>
6387
6388	* i387-fp.c (i387_cache_to_xsave): Only write x87 control
6389	registers to the cache if their values have changed.
6390	(i387_xsave_to_cache): Provide default values for x87 control
6391	registers when these features are available, but disabled.
6392	* regcache.c (supply_register_by_name_zeroed): New function.
6393	* regcache.h (supply_register_by_name_zeroed): Declare new
6394	function.
6395
63962018-05-07  Tom Tromey  <tom@tromey.com>
6397
6398	* configure: Rebuild.
6399
64002018-05-04  Tom Tromey  <tom@tromey.com>
6401
6402	* configure: Rebuild.
6403
64042018-05-04  Jan Kratochvil  <jan.kratochvil@redhat.com>
6405	    Pedro Alves <palves@redhat.com>
6406
6407	* linux-aarch64-low.c (aarch64_stopped_data_address):
6408	Likewise.
6409
64102018-04-27  Tom Tromey  <tom@tromey.com>
6411
6412	* configure: Rebuild.
6413
64142018-04-23  Tom Tromey  <tom@tromey.com>
6415
6416	* configure: Rebuild.
6417
64182018-04-19  Simon Marchi  <simon.marchi@ericsson.com>
6419
6420	* Makefile.in (depcomp): Add "..".
6421	(all_deps_files): New and use it.
6422
64232018-04-18  Alan Hayward  <alan.hayward@arm.com>
6424
6425	* configure.srv (aarch64*-*-linux*): Don't include xml.
6426	(i[34567]86-*-cygwin*): Likewise.
6427	(i[34567]86-*-linux*): Likewise.
6428	(i[34567]86-*-lynxos*): Likewise.
6429	(i[34567]86-*-mingw32ce*): Likewise.
6430	(i[34567]86-*-mingw*): Likewise.
6431	(i[34567]86-*-nto*): Likewise.
6432	(tic6x-*-uclinux): Likewise.
6433	(x86_64-*-linux*): Likewise.
6434	(x86_64-*-mingw*): Likewise.
6435	(x86_64-*-cygwin*): Likewise.
6436
64372018-04-18  Alan Hayward  <alan.hayward@arm.com>
6438
6439	* tdesc.c: Remove xml parameter.
6440
64412018-04-18  Alan Hayward  <alan.hayward@arm.com>
6442
6443	* server.c (get_features_xml): Remove cast.
6444	* tdesc.c (void target_desc::accept): Fill in function.
6445	(tdesc_get_features_xml): Remove old xml creation.
6446	(print_xml_feature::visit_pre): Add xml vistor.
6447	* tdesc.h (struct target_desc): Make xmltarget mutable.
6448	(tdesc_get_features_xml): Remove declaration.
6449
64502018-04-18  Alan Hayward  <alan.hayward@arm.com>
6451
6452	* tdesc.c (tdesc_architecture_name): Add new function.
6453	(tdesc_osabi_name): Likewise.
6454	(tdesc_get_features_xml): Use new functions.
6455
64562018-04-18  Alan Hayward  <alan.hayward@arm.com>
6457
6458	* tdesc.c (tdesc_create_flags): Remove.
6459	(tdesc_add_flag): Likewise.
6460	(tdesc_named_type): Likewise.
6461	(tdesc_create_union): Likewise.
6462	(tdesc_create_struct): Likewise.
6463	(tdesc_create_vector): Likewise.
6464	(tdesc_add_bitfield): Likewise.
6465	(tdesc_add_field): Likewise.
6466	(tdesc_set_struct_size): Likewise.
6467
64682018-04-18  Alan Hayward  <alan.hayward@arm.com>
6469
6470	* tdesc.c (~target_desc): Remove implictly deleted items.
6471	(init_target_desc): Iterate all features.
6472	(tdesc_get_features_xml): Use vector.
6473	(tdesc_create_feature): Create feature.
6474	* tdesc.h (tdesc_feature) Remove
6475	(target_desc): Add features.
6476
64772018-04-18  Alan Hayward  <alan.hayward@arm.com>
6478
6479	* Makefile.in: Add common/tdesc.c
6480	* tdesc.c (init_target_desc): init all reg_defs from register
6481	vector.
6482	(tdesc_create_reg): Create tdesc_reg.
6483	* tdesc.h (tdesc_feature): Add register vector.
6484
64852018-03-30  Simon Marchi  <simon.marchi@polymtl.ca>
6486
6487	* tdesc.h (struct target_desc) <features>: Change type to
6488	std::vector<std::string>.
6489	* tdesc.c (target_desc::~target_desc): Adjust to std::vector
6490	changes.
6491	(tdesc_get_features_xml): Likewise.
6492	(tdesc_create_feature): Likewise.
6493
64942018-03-26  Alan Hayward  <alan.hayward@arm.com>
6495
6496	* regcache.c (find_register_by_number): Return a ref.
6497	(find_regno): Use references.
6498	(register_size): Likewise.
6499	(register_data): Likewise.
6500	* tdesc.c (target_desc::~target_desc): Remove free calls.
6501	(target_desc::operator==): Use std::vector compare.
6502	(init_target_desc): Use reference.
6503	(tdesc_create_reg): Use reg constructors.
6504	* tdesc.h (struct target_desc): Replace pointer with object.
6505
65062018-03-23  Alan Hayward  <alan.hayward@arm.com>
6507
6508	* regcache.c (find_register_by_number): Make static.
6509	(find_regno): Use find_register_by_number
6510	* regcache.h (struct reg): Remove declaration.
6511
65122018-03-23  Alan Hayward  <alan.hayward@arm.com>
6513
6514	* tdesc.c (target_desc::~target_desc): Move to here.
6515	(target_desc::operator==): Likewise.
6516	* tdesc.h (target_desc::~target_desc): Move from here.
6517	(target_desc::operator==): Likewise.
6518
65192018-03-22  Andreas Arnez  <arnez@linux.vnet.ibm.com>
6520
6521	* linux-s390-low.c (s390_get_wordsize): Correct brace style.
6522
65232018-03-21  Andreas Arnez  <arnez@linux.vnet.ibm.com>
6524
6525	* linux-s390-ipa.c (get_ipa_tdesc): Add handling for
6526	S390_TDESC_GS.
6527	* linux-s390-low.c (s390_get_ipa_tdesc_idx): Likewise.
6528	(initialize_low_tracepoint): Call init_registers_s390x_gs_linux64
6529	and init_registers_s390_gs_linux64.
6530
65312018-03-21  Andreas Arnez  <arnez@linux.vnet.ibm.com>
6532
6533	* linux-s390-low.c (s390_fill_gs): Remove function.
6534	(s390_fill_gsbc): Remove function.
6535	(s390_regsets): Set fill functions for the guarded storage regsets
6536	to NULL.
6537
65382018-03-21  Andreas Arnez  <arnez@linux.vnet.ibm.com>
6539
6540	* linux-s390-low.c (s390_get_hwcap): Replace tdesc parameter by
6541	the word size.  Add comment.
6542	(s390_get_wordsize): New function.
6543	(s390_arch_setup): No longer select a temporary tdesc to fetch the
6544	pswm with it.  Instead, use s390_get_wordsize to determine the
6545	word size first and derive the correct tdesc from that directly.
6546
65472018-03-16  Simon Marchi  <simon.marchi@polymtl.ca>
6548
6549	* Makefile.in: Include silent-rules.mk.
6550	(srcdir, abs_top_srcdir, abs_srcdir, VPATH): Move up.
6551	(COMPILE): Add ECHO_CXX.
6552	(gdbserver$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
6553	(gdbreplay$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
6554	($(IPA_LIB)): Add SILENCE and ECHO_CXXLD.
6555	(version-generated.c): Add ECHO_GEN.
6556	(stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN_GENERATED.
6557	(IPAGENT_COMPILE): Add ECHO_CXX.
6558	(%-generated.c): Add ECHO_REGDAT.
6559
65602018-03-14  Tom Tromey  <tom@tromey.com>
6561
6562	PR cli/14977:
6563	* ax.c (ax_printf): Special case for NULL.
6564
65652018-03-08  Simon Marchi  <simon.marchi@polymtl.ca>
6566
6567	* linux-low.c (linux_qxfer_libraries_svr4): Use
6568	xml_escape_text_append.
6569
65702018-03-08  Simon Marchi  <simon.marchi@polymtl.ca>
6571
6572	* linux-low.c (linux_qxfer_libraries_svr4): Use std::string.
6573
65742018-03-02  Simon Marchi  <simon.marchi@polymtl.ca>
6575
6576	* server.c (handle_general_set): Remove unnecessary xstrdup.
6577
65782018-03-02  Simon Marchi  <simon.marchi@polymtl.ca>
6579
6580	* server.c (parse_debug_format_options): Adjust to
6581	delim_string_to_char_ptr_vec changes.
6582	* thread-db.c (thread_db_load_search): Adjust to
6583	dirnames_to_char_ptr_vec changes.
6584
65852018-03-01  Markus Metzger  <markus.t.metzger@intel.com>
6586
6587	* target.h (target_enable_btrace, target_disable_btrace)
6588	(target_read_btrace, target_read_btrace_conf): Turn macro into
6589	inline function.  Throw error if target method is not defined.
6590	* server.c (handle_qxfer_btrace handle_qxfer_btrace_conf): Remove
6591	check for btrace target method.  Be prepared to handle exceptions
6592	from btrace target methods.
6593
65942018-02-28  Sergio Durigan Junior  <sergiodj@redhat.com>
6595
6596	* server.c (captured_main): Change order of error message printed
6597	when the current working directory cannot be found.
6598
65992018-02-28  Sergio Durigan Junior  <sergiodj@redhat.com>
6600
6601	* server.c: Include "filenames.h" and "pathstuff.h".
6602	(program_name): Delete variable.
6603	(program_path): New anonymous class.
6604	(get_exec_wrapper): Use "program_path" instead of
6605	"program_name".
6606	(handle_v_run): Likewise.
6607	(captured_main): Likewise.
6608	(process_serial_event): Likewise.
6609
66102018-02-28  Sergio Durigan Junior  <sergiodj@redhat.com>
6611
6612	* Makefile.in (SFILES): Add "$(srcdir)/common/pathstuff.c".
6613	(OBJS): Add "pathstuff.o".
6614	* server.c (current_directory): New global variable.
6615	(captured_main): Initialize "current_directory".
6616
66172018-02-26  Alan Hayward  <alan.hayward@arm.com>
6618
6619	* tdesc.c: Use common/tdesc.h.
6620	* tdesc.h: Likewise.
6621
66222018-02-20  Alan Hayward  <alan.hayward@arm.com>
6623	    Simon Marchi  <simon.marchi@ericsson.com>
6624
6625	* Makefile.in: Switch order of make rules.
6626
66272018-02-19  Alan Hayward  <alan.hayward@arm.com>
6628
6629	* Makefile.in: Add common directory in build.
6630	* configure.ac: Add common reference.
6631	* configure: Regenerate.
6632
66332018-02-09  Markus Metzger  <markus.t.metzger@intel.com>
6634
6635	* linux-low.c (linux_target_ops): Remove linux_supports_btrace.
6636	* nto-low.c (nto_target_ops): Remove NULL for supports_btrace.
6637	* spu-low.c (spu_target_ops): Likewise.
6638	* win32-low.c (win32_target_ops): Likewise.
6639	* server.c (supported_btrace_packets): Report packets unconditionally.
6640	* target.h (target_ops) <supports_btrace>: Remove.
6641	(target_supports_btrace): Remove.
6642
66432018-02-09  Markus Metzger  <markus.t.metzger@intel.com>
6644
6645	* server.c (handle_btrace_enable_bts, handle_btrace_enable_pt)
6646	(handle_btrace_disable): Change return type to void.  Use exceptions
6647	to report errors.
6648	(handle_btrace_general_set): Catch exception and copy message to
6649	return message.
6650
66512018-02-08  Tom Tromey  <tom@tromey.com>
6652
6653	* linux-low.c (install_software_single_step_breakpoints): Use
6654	make_scoped_restore.
6655	* inferiors.c (make_cleanup_restore_current_thread): Remove.
6656	(do_restore_current_thread_cleanup): Remove.
6657	* gdbthread.h (make_cleanup_restore_current_thread): Don't
6658	declare.
6659
66602018-02-08  Tom Tromey  <tom@tromey.com>
6661
6662	* mem-break.c (set_raw_breakpoint_at): Use
6663	gdb::unique_xmalloc_ptr.
6664
66652018-01-30  Pedro Alves  <palves@redhat.com>
6666
6667	PR gdb/13211
6668	* target.c (target_terminal::terminal_state): Rename to ...
6669	(target_terminal::m_terminal_state): ... this.
6670
66712018-01-19  James Clarke  <jrtc27@jrtc27.com>
6672
6673	* linux-low.c (handle_extended_wait): Surround call to
6674	thread_db_notice_clone with #ifdef USE_THREAD_DB.
6675
66762018-01-17  Simon Marchi  <simon.marchi@ericsson.com>
6677
6678	* linux-low.c (attach_proc_task_lwp_callback): Adjust to
6679	linux_ptrace_attach_fail_reason_string now returning an
6680	std::string.
6681	(linux_attach): Likewise.
6682	* thread-db.c (attach_thread): Likewise.
6683
66842018-01-17  Eldar Abusalimov  <eldar.abusalimov@jetbrains.com>
6685
6686	PR gdb/21559
6687	* configure.ac: Include <sys/types.h> prior to <sys/user.h> when
6688	checking for fs_base/gs_base fields in struct user_regs_struct.
6689	* configure: Regenerate.
6690
66912018-01-16  Yao Qi  <yao.qi@linaro.org>
6692
6693	PR gdb/18749
6694	* linux-low.c (fetch_register): Call supply_register instead of
6695	error.
6696
66972018-01-08  Yao Qi  <yao.qi@linaro.org>
6698	    Simon Marchi  <simon.marchi@ericsson.com>
6699
6700	* Makefile.in (OBS): Remove selftest.o.
6701	* configure.ac: Set srv_selftest_objs if $development is true.
6702	(GDBSERVER_DEPFILES): Append $srv_selftest_objs.
6703	* configure: Re-generated.
6704	* server.c (captured_main): Wrap variable selftest_filter with
6705	GDB_SELF_TEST.
6706
67072018-01-07  Simon Marchi  <simon.marchi@polymtl.ca>
6708
6709	* server.c (parse_debug_format_options): Return std::string.
6710	(handle_monitor_command, captured_main): Adjust.
6711
67122018-01-05  Pedro Alves  <palves@redhat.com>
6713
6714	PR gdb/18653
6715	* server.c (captured_main): Pass quiet=false to
6716	save_original_signals_state.
6717
67182018-01-01  Joel Brobecker  <brobecker@adacore.com>
6719
6720	* gdbreplay.c (gdbreplay_version): Update copyright year in
6721	version message.
6722	* server.c (gdbserver_version): Likewise.
6723
67242017-12-08  Tom Tromey  <tom@tromey.com>
6725
6726	* ax.c (ax_printf): Update.
6727
67282017-12-07  Yao Qi  <yao.qi@linaro.org>
6729
6730	* linux-aarch64-ipa.c (initialize_low_tracepoint): Call
6731	aarch64_linux_read_description.
6732	* linux-amd64-ipa.c (idx2mask): New array.
6733	(get_ipa_tdesc): Move idx2mask out.
6734	(initialize_low_tracepoint): Initialize target descriptions.
6735	* linux-i386-ipa.c (idx2mask): New array.
6736	(get_ipa_tdesc): Move idx2mask out.
6737	(initialize_low_tracepoint): Initialize target descriptions.
6738
67392017-12-05  Simon Marchi  <simon.marchi@polymtl.ca>
6740
6741	* tdesc.c (struct tdesc_type): Change return type.
6742	(tdesc_add_flag): Change parameter type.
6743	(tdesc_add_bitfield): Likewise.
6744	(tdesc_add_field): Likewise.
6745	(tdesc_set_struct_size): Likewise.
6746
67472017-12-05  Simon Marchi  <simon.marchi@ericsson.com>
6748
6749	* regcache.c (registers_to_string): Remove unused variable.
6750
67512017-12-02  Simon Marchi  <simon.marchi@polymtl.ca>
6752
6753	* inferiors.c (for_each_inferior_with_data): Remove.
6754	* inferiors.h (for_each_inferior_with_data): Remove.
6755	* server.c (handle_qxfer_threads_worker): Change parameter type.
6756	(handle_qxfer_threads_proper): Use for_each_thread.
6757
67582017-12-02  Simon Marchi  <simon.marchi@polymtl.ca>
6759
6760	* inferiors.c (for_each_inferior): Remove.
6761	(clear_inferiors): Use for_each_thread.
6762	* inferiors.h (for_each_inferior): Remove.
6763	* linux-low.c (linux_wait_for_event_filtered): Use
6764	for_each_thread.
6765	(linux_stabilize_threads): Likewise.
6766	* regcache.c (regcache_release): Likewise.
6767	* server.c (gdb_wants_all_threads_stopped): Likewise.
6768	(clear_pending_status_callback): Remove.
6769	(handle_status): Use for_each_thread.
6770	(captured_main): Likewise.
6771	* win32-low.c (child_init_thread_list): Likewise.
6772	(win32_clear_inferiors): Likewise.
6773	(fake_breakpoint_event): Likewise.
6774
67752017-12-02  Simon Marchi  <simon.marchi@polymtl.ca>
6776
6777	* inferiors.h (find_inferior): Remove.
6778	* inferiors.c (find_inferior): Remove.
6779
67802017-12-02  Simon Marchi  <simon.marchi@polymtl.ca>
6781
6782	* linux-low.c (resume_status_pending_p): Update comment.
6783	(need_step_over_p): Update comment.
6784
67852017-12-02  Simon Marchi  <simon.marchi@polymtl.ca>
6786
6787	* linux-low.c (proceed_one_lwp): Return void, change parameter
6788	type.
6789	(unsuspend_and_proceed_one_lwp): Likewise.
6790	(proceed_all_lwps): Use for_each_thread.
6791	(unstop_all_lwps): Likewise.
6792
67932017-12-02  Simon Marchi  <simon.marchi@polymtl.ca>
6794
6795	* linux-low.c (linux_resume_one_thread): Return void, take
6796	parameter directly.
6797	(linux_resume): Use for_each_thread.
6798
67992017-12-02  Simon Marchi  <simon.marchi@polymtl.ca>
6800
6801	* linux-low.c (send_sigstop_callback): Return void, change
6802	parameter type.  Rename to...
6803	(send_sigstop): ... this.
6804	(suspend_and_send_sigstop_callback): Return void, change parameter
6805	type.  Rename to...
6806	(suspend_and_send_sigstop): ... this.
6807	(stop_all_lwps): Use for_each_thread.
6808
68092017-12-02  Simon Marchi  <simon.marchi@polymtl.ca>
6810
6811	* linux-low.c (lwp_running): Return bool, remove unused
6812	argument.
6813	(linux_stabilize_threads): Use find_thread.
6814
68152017-12-02  Simon Marchi  <simon.marchi@polymtl.ca>
6816
6817	* linux-low.c (select_singlestep_lwp_callback): Remove.
6818	(count_events_callback): Remove.
6819	(select_event_lwp_callback): Remove.
6820	(select_event_lwp): Use find_thread/for_each_thread.
6821
68222017-12-02  Simon Marchi  <simon.marchi@polymtl.ca>
6823
6824	* linux-low.c (not_stopped_callback): Return bool, take filter
6825	argument directly.
6826	(linux_wait_for_event_filtered): Use find_thread.
6827	(linux_wait_1): Likewise.
6828
68292017-12-02  Simon Marchi  <simon.marchi@polymtl.ca>
6830
6831	* linux-low.c (same_lwp): Remove.
6832	(find_lwp_pid): Use find_thread.
6833
68342017-12-02  Simon Marchi  <simon.marchi@polymtl.ca>
6835
6836	* linux-low.c (delete_lwp_callback): Remove.
6837	(linux_mourn): Use for_each_thread.
6838
68392017-12-02  Simon Marchi  <simon.marchi@polymtl.ca>
6840
6841	* linux-low.c (linux_detach_lwp_callback): Return void, remove
6842	args parameter, don't check for pid.
6843	(linux_detach): Use for_each_thread.
6844
68452017-12-02  Simon Marchi  <simon.marchi@polymtl.ca>
6846
6847	* linux-low.c (struct counter): Remove.
6848	(second_thread_of_pid_p): Remove.
6849	(last_thread_of_process_p): Use find_thread.
6850
68512017-12-02  Simon Marchi  <simon.marchi@polymtl.ca>
6852
6853	* inferiors.c (find_inferior_in_random): Remove.
6854	* inferiors.h (find_inferior_in_random): Remove.
6855	* linux-low.c (status_pending_p_callback): Return bool, accept
6856	parameter ptid directly.
6857	(linux_wait_for_event_filtered): Use find_thread_in_random.
6858	(linux_wait_1): Likewise.
6859
68602017-12-02  Simon Marchi  <simon.marchi@polymtl.ca>
6861
6862	* inferiors.c (find_inferior_id): Remove.
6863	(find_thread_ptid): Move implemention from find_inferior_id to
6864	here.
6865	* inferiors.h (find_inferior_id): Remove.
6866	* server.c (handle_status): Use find_thread_ptid.
6867	(process_serial_event): Likewise.
6868	* thread-db.c (find_one_thread): Likewise.
6869	(thread_db_thread_handle): Likewise.
6870	* win32-low.c (thread_rec): Likewise.
6871	(child_delete_thread): Likewise.
6872	(win32_thread_alive): Likewise.
6873	(get_child_debug_event): Likewise.
6874
68752017-12-02  Simon Marchi  <simon.marchi@polymtl.ca>
6876
6877	* linux-mips-low.c (update_watch_registers_callback): Return
6878	void, remove pid_p parameter, don't check for pid.
6879	(mips_insert_point, mips_remove_point): Use for_each_thread.
6880
68812017-12-02  Simon Marchi  <simon.marchi@polymtl.ca>
6882
6883	* lynx.low (lynx_delete_thread_callback): Remove.
6884	(lynx_mourn): Use for_each_thread.
6885
68862017-12-02  Simon Marchi  <simon.marchi@polymtl.ca>
6887
6888	* regcache.c (regcache_invalidate_one): Remove.
6889	(regcache_invalidate_pid): use for_each_thread.
6890
68912017-11-26  Tom Tromey  <tom@tromey.com>
6892
6893	* linux-low.c (linux_create_inferior): Update.
6894
68952017-11-24  Ulrich Weigand  <uweigand@de.ibm.com>
6896
6897	* spu-low.c (spu_create_inferior): Fix typo in argument name.
6898
68992017-11-24  Alan Hayward  <alan.hayward@arm.com>
6900
6901	* configure.srv: Add linux-aarch64-tdesc-selftest.o.
6902	* linux-aarch64-low.c (initialize_low_arch): Call init func.
6903	* linux-aarch64-tdesc-selftest.c: New file.
6904	* linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
6905
69062017-11-24  Alan Hayward  <alan.hayward@arm.com>
6907
6908	* configure.srv: Add new file.
6909	* linux-aarch64-low.c (initialize_low_arch): Call init func.
6910	* linux-aarch64-tdesc-selftest.c: New file.
6911	* linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
6912
69132017-11-24  Alan Hayward  <alan.hayward@arm.com>
6914
6915	* linux-aarch64-ipa.c (initialize_low_tracepoint): Remove init.
6916	* linux-aarch64-low.c (initialize_low_arch): Remove init.
6917	* linux-aarch64-tdesc.c (aarch64_linux_read_description): Add init.
6918
69192017-11-24  Alan Hayward  <alan.hayward@arm.com>
6920
6921	* configure.srv: Add new files.
6922	* linux-aarch64-ipa.c (get_ipa_tdesc): Call
6923	aarch64_linux_read_description.
6924	* linux-aarch64-low.c (aarch64_linux_read_description):
6925	Merge with aarch64_arch_setup.
6926	(aarch64_arch_setup): Call aarch64_linux_read_description.
6927	* linux-aarch64-tdesc.c: New file.
6928	* linux-aarch64-tdesc.h: New file.
6929
69302017-11-24  Yao Qi  <yao.qi@linaro.org>
6931
6932	* configure.srv: Set $srv_regobj for tic6x-linux.
6933	* linux-tic6x-low.c: Include "arch/tic6x.h" and "tdesc.h".
6934	(tic6x_read_description): Move some code to tic6x_arch_setup.
6935	(tic6x_tdesc_test): New function.
6936	(initialize_low_arch): Call selftests::register_test.
6937
69382017-11-22  Yao Qi  <yao.qi@linaro.org>
6939
6940	* remote-utils.c (prepare_resume_reply): Use memcpy.
6941
69422017-11-19  Simon Marchi  <simon.marchi@ericsson.com>
6943
6944	* linux-low.c (kill_one_lwp_callback): Return void, take
6945	argument directly, don't filter on pid.
6946	(linux_kill): Use for_each_thread.
6947
69482017-11-19  Simon Marchi  <simon.marchi@ericsson.com>
6949
6950	* linux-low.c (need_step_over_p): Return bool, remove dummy
6951	argument.
6952	(linux_resume, proceed_all_lwps): Use find_thread.
6953
69542017-11-19  Simon Marchi  <simon.marchi@ericsson.com>
6955
6956	* linux-low.c (resume_status_pending_p): Return bool, remove
6957	flag_p argument.
6958	(linux_resume): Use find_thread.
6959
69602017-11-19  Simon Marchi  <simon.marchi@ericsson.com>
6961
6962	* linux-low.c (struct thread_resume_array): Remove.
6963	(linux_set_resume_request): Return void, take arguments
6964	directly.
6965	(linux_resume): Use for_each_thread.
6966
69672017-11-19  Simon Marchi  <simon.marchi@ericsson.com>
6968
6969	* linux-low.c (stuck_in_jump_pad_callback): Change prototype,
6970	return bool, remove data argument.
6971	(linux_stabilize_threads): Use find_thread.
6972
69732017-11-19  Simon Marchi  <simon.marchi@ericsson.com>
6974
6975	* linux-low.c (unsuspend_one_lwp): Remove.
6976	(unsuspend_all_lwps): Use for_each_thread, inline code from
6977	unsuspend_one_lwp.
6978
69792017-11-19  Simon Marchi  <simon.marchi@ericsson.com>
6980
6981	* gdbthread.h (find_thread): Add overload with ptid_t filter.
6982	* linux-low.c (struct iterate_over_lwps_args): Remove.
6983	(iterate_over_lwps_filter): Remove.
6984	(iterate_over_lwps): Use find_thread.
6985
69862017-11-19  Simon Marchi  <simon.marchi@ericsson.com>
6987
6988	* linux-low.c (reset_lwp_ptrace_options_callback): Remove.
6989	(linux_handle_new_gdb_connection): Use for_each_thread, inline
6990	code from reset_lwp_ptrace_options_callback.
6991
69922017-11-19  Simon Marchi  <simon.marchi@ericsson.com>
6993
6994	* linux-arm-low.c (struct update_registers_data): Remove.
6995	(update_registers_callback): Return void, take arguments
6996	directly, don't check thread's pid.
6997	(arm_insert_point, arm_remove_point): Use for_each_thread.
6998
69992017-11-19  Simon Marchi  <simon.marchi@ericsson.com>
7000
7001	* win32-low.c (continue_one_thread): Return void, take argument
7002	directly.
7003	(child_continue): Use for_each_thread.
7004
70052017-11-19  Simon Marchi  <simon.marchi@ericsson.com>
7006
7007	* win32-i386-low.c (update_debug_registers_callback): Rename
7008	to ...
7009	(update_debug_registers): ... this, return void, remove pid_p arg.
7010	(x86_dr_low_set_addr, x86_dr_low_set_control): Use for_each_thread.
7011
70122017-11-17  Simon Marchi  <simon.marchi@polymtl.ca>
7013
7014	* inferiors.h (struct process_info): Add constructor, initialize
7015	fields..
7016	<syscalls_to_catch>: Change type to std::vector<int>.
7017	* inferiors.c (add_process): Allocate process_info with new.
7018	(remove_process): Free process_info with delete.
7019	* linux-low.c (handle_extended_wait): Adjust.
7020	(gdb_catching_syscalls_p, gdb_catch_this_syscall_p): Adjust.
7021	* server.c (handle_general_set): Adjust.
7022
70232017-11-16  Pedro Alves  <palves@redhat.com>
7024
7025	* remote-utils.c (remote_close): Block SIGIO signals instead of
7026	uninstalling the SIGIO handler.
7027
70282017-11-16  Alan Hayward  <alan.hayward@arm.com>
7029
7030	* tdesc.c (tdesc_get_features_xml): Allow null osabi.
7031
70322017-11-16  Yao Qi  <yao.qi@linaro.org>
7033
7034	* linux-tic6x-low.c (tic6x_fill_gregset): Cast buf.
7035	(tic6x_store_gregset): Likewise.
7036	(tic6x_usrregs_info): Move it up.
7037
70382017-11-15  Alan Hayward  <alan.hayward@arm.com>
7039
7040	* Makefile.in: Update arch rules.
7041	* configure.srv: Explicitly mark arch/ files.
7042
70432017-11-13  Andreas Schwab  <schwab@suse.de>
7044
7045	* linux-m68k-low.c (m68k_supports_hardware_single_step): New
7046	function.
7047	(struct linux_target_ops) <supports_hardware_single_step>: Initialize.
7048
70492017-11-06  Pedro Alves  <palves@redhat.com>
7050
7051	* config.in, configure: Regenerate.
7052
70532017-10-27  Simon Marchi  <simon.marchi@ericsson.com>
7054
7055	* target.c (struct thread_search): Remove.
7056	(thread_search_callback): Remove.
7057	(prepare_to_access_memory): Use for_each_thread instead of
7058	find_inferior.  Inline code from thread_search_callback.
7059
70602017-10-27  Simon Marchi  <simon.marchi@ericsson.com>
7061
7062	* server.c (struct visit_actioned_threads_data): Remove.
7063	(visit_actioned_threads): Change prototype to take arguments
7064	directly.
7065	(resume): Use find_thread instead of find_inferior.
7066
70672017-10-27  Simon Marchi  <simon.marchi@ericsson.com>
7068
7069	* server.c (queue_stop_reply_callback): Change prototype, return
7070	void.
7071	(find_status_pending_thread_callback): Remove.
7072	(handle_status): Replace find_inferior with find_thread and
7073	for_each_thread.
7074
70752017-10-25  Alan Hayward  <alan.hayward@arm.com>
7076
7077	* linux-aarch64-low.c (aarch64_fill_gregset): Replace defines
7078	with REGNO.
7079	(aarch64_store_gregset): Likewise.
7080	(aarch64_fill_fpregset): Likewise.
7081	(aarch64_store_fpregset): Likewise.
7082
70832017-10-21  Simon Marchi  <simon.marchi@ericsson.com>
7084
7085	* gdbthread.h (find_thread, for_each_thread): New functions.
7086	* inferiors.c (thread_of_pid): Remove.
7087	(find_any_thread_of_pid): Use find_thread.
7088	* linux-low.c (num_lwps): Use for_each_thread.
7089
70902017-10-17  Yao Qi  <yao.qi@linaro.org>
7091
7092	* Makefile.in: Remove one rule.
7093	* configure.srv: Rename aarch64-insn.o with arch/aarch64-insn.o.
7094
70952017-10-17  Yao Qi  <yao.qi@linaro.org>
7096
7097	* configure.srv: Rename arm-linux.o with arch/arm-linux.o.
7098	Rename arm-get-next-pcs.o with arch/arm-get-next-pcs.o.
7099
71002017-10-17  Yao Qi  <yao.qi@linaro.org>
7101
7102	* configure.srv: Rename arm.o with arch/arm.o.
7103
71042017-10-17  Yao Qi  <yao.qi@linaro.org>
7105
7106	* Makefile.in (CONFIG_SRC_SUBDIR): New variable.
7107	(clean): Remove .o files in CONFIG_SRC_SUBDIR.
7108	(distclean): Remove DEPDIR in CONFIG_SRC_SUBDIR.
7109	(arch-i386.o, arch-amd64.o): Remove rules.
7110	(arch/%.o): New rule.
7111	Update POSTCOMPILE and COMPILE.pre.
7112	* configure.ac: Invoke AC_CONFIG_COMMANDS.
7113	* configure: Re-generated.
7114	* configure.srv: Replace arch-i386.o with arch/i386.o.
7115	Replace arch-amd64.o with arch/amd64.o.
7116
71172017-10-16  Yao Qi  <yao.qi@linaro.org>
7118
7119	* configure: Regenerated.
7120
71212017-10-14  Simon Marchi  <simon.marchi@polymtl.ca>
7122
7123	* inferiors.h: (struct inferior_list): Remove.
7124	(struct inferior_list_entry); Remove.
7125	(add_inferior_to_list, clear_inferior_list, one_inferior_p,
7126	A_I_NEXT, ALL_INFERIORS_TYPE, ALL_INFERIORS, remove_inferior,
7127	get_first_inferior): Remove.
7128	(for_each_inferior, for_each_inferior_with_data, find_inferior,
7129	find_inferior_id, find_inferior_in_random): Change signature.
7130	* inferiors.c (all_threads): Change type to
7131	std::list<thread_info *>.
7132	(get_thread): Remove macro.
7133	(find_inferior, find_inferior_id): Change signature, implement
7134	using find_thread.
7135	(find_inferior_in_random): Change signature, implement using
7136	find_thread_in_random.
7137	(for_each_inferior, for_each_inferior_with_data): Change
7138	signature, implement using for_each_thread.
7139	(add_inferior_to_list, remove_inferior): Remove.
7140	(add_thread, get_first_thread, thread_of_pid,
7141	find_any_thread_of_pid, free_one_thread, remove_thread): Update.
7142	(get_first_inferior, one_inferior_p, clear_inferior_list):
7143	Remove.
7144	(clear_inferiors, get_thread_process): Update.
7145	* gdbthread.h: Include <list>.
7146	(struct thread_info) <entry>: Remove field.
7147	<id>: New field.
7148	(all_threads): Change type to std::list<thread_info *>.
7149	(get_first_inferior): Add doc.
7150	(find_thread, for_each_thread, find_thread_in_random): New
7151	functions.
7152	(current_ptid, pid_of, ptid_of, lwpid_of): Update.
7153	* linux-arm-low.c (update_registers_callback): Update.
7154	* linux-low.c (second_thread_of_pid_p): Update.
7155	(kill_one_lwp_callback, linux_detach_lwp_callback,
7156	delete_lwp_callback, status_pending_p_callback, same_lwp,
7157	find_lwp_pid, num_lwps, iterate_over_lwps_filter,
7158	iterate_over_lwps, not_stopped_callback,
7159	resume_stopped_resumed_lwps, count_events_callback,
7160	select_singlestep_lwp_callback, select_event_lwp_callback,
7161	unsuspend_one_lwp, linux_wait_1, send_sigstop_callback,
7162	suspend_and_send_sigstop_callback, wait_for_sigstop,
7163	stuck_in_jump_pad_callback, move_out_of_jump_pad_callback,
7164	lwp_running, linux_set_resume_request, resume_status_pending_p,
7165	need_step_over_p, start_step_over, linux_resume_one_thread,
7166	proceed_one_lwp, unsuspend_and_proceed_one_lwp,
7167	reset_lwp_ptrace_options_callback): Update.
7168	* linux-mips-low.c (update_watch_registers_callback): Update.
7169	* regcache.c (regcache_invalidate_one, regcache_invalidate):
7170	Update.
7171	(free_register_cache_thread_one): Remove.
7172	(regcache_release): Update.
7173	* server.c (handle_btrace_enable_bts, handle_btrace_enable_pt,
7174	handle_qxfer_threads_worker): Update.
7175	(handle_query): Update, use list iterator.
7176	(visit_actioned_threads, handle_pending_status,
7177	queue_stop_reply_callback, gdb_wants_all_threads_stopped,
7178	clear_pending_status_callback, set_pending_status_callback,
7179	find_status_pending_thread_callback, handle_status,
7180	process_serial_event): Update.
7181	* target.c (thread_search_callback): Update.
7182	* thread-db.c (thread_db_get_tls_address): Update.
7183	* tracepoint.c (tracepoint_finished_step, tracepoint_was_hit):
7184	Update.
7185	* win32-i386-low.c (update_debug_registers_callback): Update.
7186	* win32-low.c (delete_thread_info, child_delete_thread,
7187	continue_one_thread, suspend_one_thread,
7188	get_child_debug_event): Adjust.
7189
71902017-10-14  Simon Marchi  <simon.marchi@polymtl.ca>
7191
7192	* gdbthread.h (ptid_of, pid_of, lwpid_of): New functions.
7193	* inferiors.h: Include <list>.
7194	(struct process_info) <entry>: Remove field.
7195	<pid>: New field.
7196	(pid_of): Change macro to function.
7197	(ptid_of, lwpid_of): Remove macro.
7198	(all_processes): Change type to std::list<process_info *>.
7199	(ALL_PROCESSES): Remove macro.
7200	(for_each_process, find_process): New function.
7201	* inferiors.c (all_processes): Change type to
7202	std::list<process_info *>.
7203	(find_thread_process): Adjust.
7204	(add_process): Likewise.
7205	(remove_process): Likewise.
7206	(find_process_pid): Likewise.
7207	(get_first_process): Likewise.
7208	(started_inferior_callback): Remove.
7209	(have_started_inferiors_p): Adjust.
7210	(attached_inferior_callback): Remove.
7211	(have_attached_inferiors_p): Adjust.
7212	* linux-low.c (check_zombie_leaders): Likewise.
7213	* linux-x86-low.c (x86_arch_setup_process_callback): Remove.
7214	(x86_linux_update_xmltarget): Adjust.
7215	* server.c (handle_query): Likewise.
7216	(gdb_reattached_process): Remove.
7217	(handle_status): Adjust.
7218	(kill_inferior_callback): Likewise.
7219	(detach_or_kill_inferior): Remove.
7220	(print_started_pid): Likewise.
7221	(print_attached_pid): Likewise.
7222	(detach_or_kill_for_exit): Update.
7223	(process_serial_event): Likewise.
7224	* linux-arm-low.c (arm_new_fork): Likewise.
7225
72262017-10-14  Simon Marchi  <simon.marchi@polymtl.ca>
7227
7228	* dll.h: Include <list>.
7229	(struct dll_info): Add constructor.
7230	<entry>: Remove field.
7231	(all_dlls): Change type to std::list<dll_info>.
7232	* dll.c: Include <algorithm>.
7233	(get_dll): Remove macro.
7234	(all_dlls): Change type to std::list<dll_info *>.
7235	(free_one_dll): Remove.
7236	(match_dll): Likewise.
7237	(loaded_dll): Adjust.
7238	(unloaded_dll): Adjust to all_dlls type change, use
7239	std::find_if.  Inline code from match_dll.
7240	(clear_dlls): Adjust to all_dlls type change.
7241	* server.c (emit_dll_description): Remove.
7242	(handle_qxfer_libraries): Adjust to all_dlls type change,
7243	integrate emit_dll_description's functionality.
7244
72452017-10-12  Simon Marchi  <simon.marchi@ericsson.com>
7246
7247	* linux-low.h (struct linux_target_ops) <delete_process>: New
7248	field.
7249	* linux-low.c (linux_mourn): Call the_low_target.delete_process.
7250	* linux-aarch64-low.c (aarch64_linux_delete_process): New.
7251	(struct linux_target_ops): Add delete_process callback.
7252	* linux-arm-low.c (arm_delete_process): New.
7253	(struct linux_target_ops): Add delete_process callback.
7254	* linux-bfin-low.c (struct linux_target_ops): Likewise.
7255	* linux-crisv32-low.c (struct linux_target_ops): Likewise.
7256	* linux-m32r-low.c (struct linux_target_ops): Likewise.
7257	* linux-mips-low.c (mips_linux_delete_process): New.
7258	(struct linux_target_ops): Add delete_process callback.
7259	* linux-ppc-low.c (struct linux_target_ops): Likewise.
7260	* linux-s390-low.c (struct linux_target_ops): Likewise.
7261	* linux-sh-low.c (struct linux_target_ops): Likewise.
7262	* linux-tic6x-low.c (struct linux_target_ops): Likewise.
7263	* linux-tile-low.c (struct linux_target_ops): Likewise.
7264	* linux-x86-low.c (x86_linux_delete_process): New.
7265	(struct linux_target_ops): Add delete_process callback.
7266	* linux-xtensa-low.c (struct linux_target_ops): Likewise.
7267
72682017-10-12  Simon Marchi  <simon.marchi@ericsson.com>
7269
7270	* linux-aarch64-low.c (the_low_target): Add thread delete
7271	callback.
7272	* linux-arm-low.c (arm_delete_thread): New function.
7273	(the_low_target): Add thread delete callback.
7274	* linux-bfin-low.c (the_low_target): Likewise.
7275	* linux-crisv32-low.c (the_low_target): Likewise.
7276	* linux-low.c (delete_lwp): Invoke delete_thread callback if
7277	set.
7278	* linux-low.h (struct linux_target_ops) <delete_thread>: New
7279	field.
7280	* linux-m32r-low.c (the_low_target): Add thread delete callback.
7281	* linux-mips-low.c (mips_linux_delete_thread): New function.
7282	(the_low_target): Add thread delete callback.
7283	* linux-ppc-low.c (the_low_target): Likewise.
7284	* linux-s390-low.c (the_low_target): Likewise.
7285	* linux-sh-low.c (the_low_target): Likewise.
7286	* linux-tic6x-low.c (the_low_target): Likewise.
7287	* linux-tile-low.c (the_low_target): Likewise.
7288	* linux-x86-low.c (the_low_target): Likewise.
7289	* linux-xtensa-low.c (the_low_target): Likewise.
7290
72912017-10-06  Yuanhui Zhang  <asmwarrior@gmail.com>
7292
7293	* win32-low.c: Include "common-inferior.h".
7294
72952017-10-04  Sergio Durigan Junior  <sergiodj@redhat.com>
7296
7297	* inferiors.c (set_inferior_cwd): New function.
7298	* server.c (handle_general_set): Handle QSetWorkingDir packet.
7299	(handle_query): Inform that QSetWorkingDir is supported.
7300	* win32-low.c (create_process): Pass the inferior's cwd to
7301	CreateProcess.
7302
73032017-10-04  Sergio Durigan Junior  <sergiodj@redhat.com>
7304
7305	* inferiors.c (current_inferior_cwd): New global variable.
7306	(get_inferior_cwd): New function.
7307	* inferiors.h (struct process_info) <cwd>: New field.
7308
73092017-10-04  Sergio Durigan Junior  <sergiodj@redhat.com>
7310
7311	* Makefile.in (SFILES): Add $(srcdir)/common/gdb_tilde_expand.c.
7312	(OBS): Add gdb_tilde_expand.o.
7313
73142017-10-02  Simon Marchi  <simon.marchi@ericsson.com>
7315
7316	* lynx-i386-low.c (lynx_i386_arch_setup): Call init_target_desc.
7317	* nto-x86-low.c (nto_x86_arch_setup): Likewise.
7318
73192017-09-29  Pedro Alves  <palves@redhat.com>
7320
7321	* ax.c (gdb_parse_agent_expr): Constify.
7322	* ax.h (gdb_parse_agent_expr): Constify.
7323	* mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
7324	Constify.
7325	* mem-break.h (add_breakpoint_condition, add_breakpoint_commands): Constify.
7326	* remote-utils.c (hex_or_minus_one, read_ptid): Constify.
7327	* remote-utils.h (read_ptid): Constify.
7328	* server.c (handle_qxfer_exec_file, handle_query, handle_v_cont)
7329	(process_point_options, process_serial_event): Constify.
7330	* tracepoint.c (add_tracepoint_action, cmd_qtdp, cmd_qtdpsrc)
7331	(cmd_qtdv, cmd_qtenable_disable, cmd_qtro, cmd_qtframe, cmd_qtp)
7332	(cmd_qtbuffer): Constify.
7333
73342017-09-29  Pedro Alves  <palves@redhat.com>
7335
7336	* proc-service.c (ps_pdread): Return PS_ERR if reading memory
7337	fails.
7338
73392017-09-29  Pedro Alves  <palves@redhat.com>
7340
7341	* linux-low.c (handle_extended_wait): Pass parent thread instead
7342	of process to thread_db_notice_clone.
7343	* linux-low.h (thread_db_notice_clone): Replace parent process
7344	parameter with parent thread parameter.
7345	* thread-db.c (find_one_thread): Add comment.
7346	(thread_db_notice_clone): Replace parent process parameter with
7347	parent thread parameter.  Temporarily switch to the parent thread.
7348
73492017-09-26  Sergio Durigan Junior  <sergiodj@redhat.com>
7350
7351	* gdbthread.h: Include "common-gdbthread.h".
7352	* inferiors.c (switch_to_thread): Use "gdb_assert" instead of
7353	"if" when validating the ptid.
7354	* remote-utils.c: Include "gdbthread.h".
7355	(prepare_resume_reply): Use "switch_to_thread".
7356	* target.c (done_accessing_memory): Likewise.
7357
73582017-09-25  Andreas Arnez  <arnez@linux.vnet.ibm.com>
7359
7360	* configure.srv (s390*-*-linux*): Add s390-gs-linux64.o and
7361	s390x-gs-linux64.o to srv_regobj.  Add s390-gs-linux64.xml,
7362	s390x-gs-linux64.xml, s390-gs.xml, and s390-gsbc.xml to
7363	srv_xmlfiles.  Add s390-gs-linux64-ipa.o and
7364	s390x-gs-linux64-ipa.o to ipa_obj.
7365	* linux-s390-low.c (HWCAP_S390_GS): New define.
7366	(s390_fill_gs, s390_store_gs, s390_fill_gsbc, s390_store_gsbc):
7367	New functions.
7368	(s390_regsets): Add regsets for NT_S390_GS_CB and NT_S390_GS_BC.
7369	(s390_arch_setup): Check for guarded-storage support and choose
7370	appropriate tdesc.
7371	(initialize_low_arch): Invoke init_registers_s390_gs_linux64 and
7372	init_registers_s390x_gs_linux64.
7373	* linux-s390-tdesc.h (enum s390_linux_tdesc) <S390_TDESC_GS>: New
7374	enum value.
7375	(init_registers_s390x_gs_linux64, tdesc_s390x_gs_linux64)
7376	(init_registers_s390_gs_linux64, tdesc_s390_gs_linux64): Declare.
7377
73782017-09-22  Simon Marchi  <simon.marchi@ericsson.com>
7379
7380	* win32-i386-low.c (i386_arch_setup): Call init_target_desc.
7381
73822017-09-21  Kevin Buettner  <kevinb@redhat.com>
7383
7384	* linux-low.h (struct lwp_info): Add new field, thread_handle.
7385	(thread_db_thread_handle): Declare.
7386	* linux-low.c (linux_target_ops): Initialize thread_handle.
7387	* server.c (handle_qxfer_threads_worker): Add support for
7388	"handle" attribute.
7389	* target.h (struct target_ops): Add new function pointer,
7390	thread_handle.
7391	(target_thread_handle): Define.
7392	* thread-db.c (find_one_thread, attach_thread): Set thread_handle
7393	field in lwp.
7394	(thread_db_thread_handle): New function.
7395
73962017-09-21  Kevin Buettner  <kevinb@redhat.com>
7397
7398	* linux-low.c (handle_extended_wait): Call thread_db_notice_clone().
7399	* linux-low.h (thread_db_notice_clone): Declare.
7400	* thread-db.c (thread_db_notice_clone): New function.
7401
74022017-09-21  Pedro Alves  <palves@redhat.com>
7403
7404	* server.c (gdb_read_memory, handle_status, process_serial_event)
7405	(handle_serial_event, handle_target_event): Adjust to
7406	set_desired_thread prototype change.
7407	* target.c (set_desired_thread): Remove 'use_general' parameter
7408	and adjust.
7409	* target.h (set_desired_thread): Remove 'use_general' parameter.
7410
74112017-09-20  Tom Tromey  <tom@tromey.com>
7412
7413	* target.c (target_terminal::terminal_state): Define.
7414	(target_terminal::init): Rename from target_terminal_init.
7415	(target_terminal::inferior): Rename from
7416	target_terminal_inferior.
7417	(target_terminal::ours): Rename from target_terminal_ours.
7418	(target_terminal::ours_for_output, target_terminal::info): New.
7419
74202017-09-16  Simon Marchi  <simon.marchi@ericsson.com>
7421
7422	* server.c (accumulate_file_name_length): Remove.
7423	(emit_dll_description): Adjust to std::string change.
7424	(handle_qxfer_libraries): Use std::string to hold document.
7425
74262017-09-16  Simon Marchi  <simon.marchi@ericsson.com>
7427
7428	* linux-low.c (linux_qxfer_libraries_svr4): Adjust to change of
7429	return type of xml_escape_text.
7430	* server.c (emit_dll_description): Likewise.
7431
74322017-09-16  Simon Marchi  <simon.marchi@ericsson.com>
7433
7434	* server.c (captured_main): Accept argument for --selftest.
7435	Update run_tests call.
7436	* linux-x86-tdesc-selftest.c (initialize_low_tdesc): Add names
7437	when registering selftests.
7438
74392017-09-16  Sergio Durigan Junior  <sergiodj@redhat.com>
7440
7441	* regcache.c (get_thread_regcache): Update code to use "std::vector"
7442	instead of "VEC" for "target_desc.reg_defs".
7443	(regcache_cpy): Likewise.
7444	(registers_to_string): Likewise.
7445	(registers_from_string): Likewise.
7446	(find_regno): Likewise.
7447	(supply_regblock): Likewise.
7448	(regcache_raw_read_unsigned): Likewise.
7449	* tdesc.c (init_target_desc): Likewise.
7450	(tdesc_create_reg): Likewise.
7451	* tdesc.h: Remove declaration of "tdesc_reg_p".  Include <vector>.
7452	(struct target_desc) <reg_defs>: Convert to "std::vector".
7453	(target_desc): Do not initialize "reg_defs".
7454	(~target_desc): Update code to use "std::vector" instead of "VEC"
7455	for "target_desc.reg_defs".
7456	(operator==): Likewise.
7457
74582017-09-15  Simon Marchi  <simon.marchi@ericsson.com>
7459
7460	* inferiors.h (thread_to_gdb_id): Remove.
7461	* inferiors.c (thread_to_gdb_id): Remove.
7462	* server.c (handle_qxfer_threads_worker, handle_query): Adjust.
7463	* lynx-low.c (lynx_resume, lynx_wait_1, lynx_fetch_registers,
7464	lynx_store_registers, lynx_read_memory, lynx_write_memory):
7465	Likewise.
7466	* nto-low.c (nto_fetch_registers, nto_store_registers,
7467	nto_stopped_by_watchpoint, nto_stopped_data_address): Likewise.
7468
74692017-09-15  Simon Marchi  <simon.marchi@ericsson.com>
7470
7471	* inferiors.h (gdb_id_to_thread_id): Remove.
7472	* inferiors.c (gdb_id_to_thread_id): Remove.
7473	* server.c (process_serial_event): Adjust to gdb_id_to_thread_id
7474	removal.  Move pid declaration closer to where it's used.
7475
74762017-09-15  Simon Marchi  <simon.marchi@ericsson.com>
7477
7478	* server.c (handle_detach): New function.
7479	(process_serial_event): Move code out, call handle_detach.
7480
74812017-09-15  Simon Marchi  <simon.marchi@ericsson.com>
7482
7483	* server.c (require_running): Rename to ...
7484	(require_running_or_return): ... this ...
7485	(require_running_or_break): ... and this.
7486	(handle_query, process_serial_event): Adjust.
7487
74882017-09-15  Simon Marchi  <simon.marchi@ericsson.com>
7489
7490	* linux-low.c (linux_set_resume_request): Remove unused
7491	variables.
7492
74932017-09-15  Simon Marchi  <simon.marchi@ericsson.com>
7494
7495	* server.c (first_thread_of): Remove.
7496	(process_serial_event): Replace usage of first_thread_of with
7497	find_any_thread_of_pid.
7498	* tracepoint.c (same_process_p): Remove.
7499	(gdb_agent_about_to_close): Replace usage of same_process_p with
7500	find_any_thread_of_pid.
7501	* linux-x86-low.c (same_process_callback): Remove.
7502	(x86_arch_setup_process_callback): Replace usage of
7503	same_process_callback with find_any_thread_of_pid.
7504	* thread-db.c (any_thread_of): Remove.
7505	(switch_to_process): Replace usage of any_thread_of with
7506	find_any_thread_of_pid.
7507	* inferiors.c (thread_pid_matches_callback): Remove.
7508	(find_thread_process): Adjust to use find_any_thread_of_pid.
7509
75102017-09-10  Sergio Durigan Junior  <sergiodj@redhat.com>
7511
7512	* regcache.c (get_thread_regcache): Guard calls to "memset"
7513	with "!VEC_empty".
7514
75152017-09-10  Sergio Durigan Junior  <sergiodj@redhat.com>
7516
7517	* linux-low.c (handle_extended_wait): Use
7518	"allocate_target_description" instead of "XNEW".
7519	* linux-x86-low.c (initialize_low_arch): Likewise.
7520
75212017-09-05  Yao Qi  <yao.qi@linaro.org>
7522
7523	* configure.srv (srv_i386_regobj): Remove.
7524	(srv_amd64_regobj): Remove.
7525	(srv_regobj): Set it to "" for x86 non-linux targets.
7526	* linux-x86-tdesc.c (i386_linux_read_description):
7527	* lynx-i386-low.c: Include x86-xstate.h and arch/i386.h.
7528	(init_registers_i386): Remove the declaration.
7529	(tdesc_i386): Remove the declaration.
7530	(lynx_i386_arch_setup): Call i386_create_target_description.
7531	* nto-x86-low.c: Likewise.
7532	* win32-i386-low.c [__x86_64__]: include arch/amd64.h.
7533	[!__x86_64__]: include arch/i386.h.
7534	(i386_arch_setup) [__x86_64__]: Call amd64_create_target_description.
7535
75362017-09-05  Yao Qi  <yao.qi@linaro.org>
7537
7538	* configure.srv (srv_amd64_linux_xmlfiles): Remove
7539	i386/amd64-XXX-linux from it.
7540
75412017-09-05  Yao Qi  <yao.qi@linaro.org>
7542
7543	* configure.srv: Empty srv_amd64_linux_regobj if $development is
7544	false.
7545	(ipa_amd64_linux_regobj): Remove.
7546	(ipa_x32_linux_regobj): Remove.
7547
75482017-09-05  Yao Qi  <yao.qi@linaro.org>
7549
7550	* Makefile.in (arch-amd64.o): New rule.
7551	* configure.srv: Append arch-amd64.o.
7552	* linux-amd64-ipa.c: Include common/x86-xstate.h.
7553	(get_ipa_tdesc): Call amd64_linux_read_description.
7554	(initialize_low_tracepoint): Don't call init_registers_x32_XXX
7555	and init_registers_amd64_XXX.
7556	* linux-x86-low.c (x86_linux_read_description): Call
7557	amd64_linux_read_description.
7558	(x86_get_ipa_tdesc_idx): Call amd64_get_ipa_tdesc_idx.
7559	(initialize_low_arch): Don't call init_registers_x32_XXX and
7560	init_registers_amd64_XXX.
7561	* linux-x86-tdesc-selftest.c: Declare init_registers_amd64_XXX
7562	and tdesc_amd64_XXX.
7563	[__x86_64__] (amd64_tdesc_test): New function.
7564	(initialize_low_tdesc) [__x86_64__]: Call init_registers_x32_XXX
7565	and init_registers_amd64_XXX.
7566	* linux-x86-tdesc.c: Include arch/amd64.h.
7567	(xcr0_to_tdesc_idx): New function.
7568	(i386_linux_read_description): New function.
7569	(amd64_get_ipa_tdesc_idx): New function.
7570	* linux-x86-tdesc.h (amd64_get_ipa_tdesc_idx): Declare.
7571	(amd64_get_ipa_tdesc): Declare.
7572
75732017-09-05  Yao Qi  <yao.qi@linaro.org>
7574
7575	* configure.srv (srv_i386_linux_xmlfiles): Remove
7576	i386/i386-XXX-linux.xml from it.
7577
75782017-09-05  Yao Qi  <yao.qi@linaro.org>
7579
7580	* configure.srv: Set srv_i386_linux_regobj empty if $development
7581	is false.
7582	* linux-i386-ipa.c (initialize_low_tracepoint): Don't call
7583	initialize_low_tdesc.
7584	* linux-x86-low.c (initialize_low_arch): Wrap initialize_low_tdesc
7585	with #if initialize_low_tdesc.
7586	* linux-x86-tdesc-selftest.c: New file.
7587	* linux-x86-tdesc.c: Move code to linux-x86-tdesc-selftest.c.
7588
75892017-09-05  Yao Qi  <yao.qi@linaro.org>
7590
7591	* Makefile.in (arch-i386.o): New rule.
7592	* configure.srv (i[34567]86-*-linux*): Add arch-i386.o.
7593	(x86_64-*-linux*): Likewise.
7594	* linux-x86-tdesc.c: Don't include ../features/i386/32bit-XXX.c,
7595	include arch/i386.h.
7596	(i386_linux_read_description): Remove code and call
7597	i386_create_target_description.
7598	* tdesc.c (allocate_target_description): New function.
7599	* tdesc.h (set_tdesc_architecture): Remove declaration.
7600	(set_tdesc_osabi): Likewise.
7601
76022017-09-05  Yao Qi  <yao.qi@linaro.org>
7603
7604	* linux-x86-tdesc.c: Don't include <inttypes.h>.
7605	(i386_linux_read_description) [!IN_PROCESS_AGENT]: Call
7606	set_tdesc_architecture and set_tdesc_osabi.  Remove code setting
7607	.xmltarget.
7608	* server.c (get_features_xml): Call tdesc_get_features_xml.
7609	* tdesc.c (set_tdesc_architecture): New function.
7610	(set_tdesc_osabi): New function.
7611	(tdesc_get_features_xml): New function.
7612	(tdesc_create_feature): Add an argument.
7613	* tdesc.h (struct target_desc) <features>: New field.
7614	<arch, osabi>: New field.
7615	(~target_desc): xfree features, arch, and osabi.
7616	(target_desc::oerator==): Don't compare .xmltarget.
7617	[!IN_PROCESS_AGENT] (set_tdesc_architecture): Declare.
7618	(set_tdesc_osabi): Likewise.
7619	(tdesc_get_features_xml): Likewise.
7620
76212017-09-05  Yao Qi  <yao.qi@linaro.org>
7622
7623	* linux-x86-tdesc.c: Include selftest.h.
7624	(i386_tdesc_test): New function.
7625	(initialize_low_tdesc): Call selftests::register_test.
7626	* tdesc.h: Include regdef.h.
7627	(target_desc): Override operator == and !=.
7628
76292017-09-05  Yao Qi  <yao.qi@linaro.org>
7630
7631	* configure.srv (srv_tgtobj): Append linux-x86-tdesc.o.
7632	(ipa_obj): Likewise.
7633	* linux-i386-ipa.c: Include common/x86-xstate.h
7634	(get_ipa_tdesc): Call i386_linux_read_description.
7635	(initialize_low_tracepoint): Don't call  init_registers_XXX
7636	functions, call initialize_low_tdesc instead.
7637	* linux-x86-low.c (x86_linux_read_description): Call
7638	i386_linux_read_description.
7639	(initialize_low_arch): Don't call init_registers_i386_XXX
7640	functions, call initialize_low_tdesc.
7641	* linux-x86-tdesc.c: New file.
7642	* linux-x86-tdesc.h (x86_linux_tdesc): New X86_TDESC_LAST.
7643	(i386_get_ipa_tdesc_idx): Declare.
7644	(i386_get_ipa_tdesc): Declare.
7645	(initialize_low_tdesc): Declare.
7646
76472017-09-05  Yao Qi  <yao.qi@linaro.org>
7648
7649	* linux-x86-low.c (x86_get_ipa_tdesc_idx): Use X86_TDESC_MMX
7650	instead of 0.
7651
76522017-09-05  Yao Qi  <yao.qi@linaro.org>
7653
7654	* Makefile.in (IPA_OBJS): Add vec-ipa.o
7655	* regcache.c (get_thread_regcache): Use VEC_length.
7656	(init_register_cache): Likewise.
7657	(regcache_cpy): Likewise.
7658	(registers_to_string): Iterate reg_defs via VEC_iterate.
7659	(find_regno): Likewise.
7660	(find_register_by_number): Use VEC_index.
7661	(register_size): Call find_register_by_number.
7662	(register_data): Call find_register_by_number.
7663	(supply_regblock): Use VEC_length.
7664	(regcache_raw_read_unsigned): Likewise.
7665	* tdesc.c (init_target_desc): Iterate reg_defs via
7666	VEC_iterate.
7667	(default_description): Update initializer.
7668	(copy_target_description): Don't update field num_registers.
7669	* tdesc.h (struct target_desc) <reg_defs>: Change it to VEC.
7670	<num_registers>: Remove.
7671
76722017-09-04  Simon Marchi  <simon.marchi@ericsson.com>
7673
7674	* Makefile.in (.SECONDARY): Define target.
7675
76762017-09-03  Simon Marchi  <simon.marchi@ericsson.com>
7677
7678	* linux-low.c (linux_wait_1): Adjust.
7679	* server.c (queue_stop_reply_callback): Adjust.
7680
76812017-08-31  Sergio Durigan Junior  <sergiodj@redhat.com>
7682
7683	* server.c (handle_general_set): Handle QEnvironmentHexEncoded,
7684	QEnvironmentUnset and QEnvironmentReset packets.
7685	(handle_query): Inform remote that QEnvironmentHexEncoded,
7686	QEnvironmentUnset and QEnvironmentReset are supported.
7687
76882017-08-25  Simon Marchi  <simon.marchi@ericsson.com>
7689
7690	* inferiors.h (inferior_target_data): Rename to ...
7691	(thread_target_data): ... this.
7692	(inferior_regcache_data): Rename to ...
7693	(thread_regcache_data): ... this.
7694	(set_inferior_regcache_data): Rename to ...
7695	(set_thread_regcache_data): ... this.
7696	* inferiors.c (inferior_target_data): Rename to ...
7697	(thread_target_data): ... this.
7698	(inferior_regcache_data): Rename to ...
7699	(thread_regcache_data): ... this.
7700	(set_inferior_regcache_data): Rename to ...
7701	(set_thread_regcache_data): ... this.
7702	(free_one_thread): Update.
7703	* linux-low.h (get_thread_lwp): Update.
7704	* regcache.c (get_thread_regcache): Update.
7705	(regcache_invalidate_thread): Update.
7706	(free_register_cache_thread): Update.
7707	* win32-i386-low.c (update_debug_registers_callback): Update.
7708	(win32_get_current_dr): Update.
7709	* win32-low.c (thread_rec): Update.
7710	(delete_thread_info): Update.
7711	(continue_one_thread): Update.
7712	(suspend_one_thread): Update.
7713
77142017-08-24  Simon Marchi  <simon.marchi@ericsson.com>
7715
7716	* inferiors.c (set_inferior_target_data): Remove.
7717	* inferiors.h (set_inferior_target_data): Remove.
7718
77192017-08-18  Yao Qi  <yao.qi@linaro.org>
7720
7721	* Makefile.in (OBS): Add selftest.o.
7722	* configure.ac: AC_DEFINE GDB_SELF_TEST if $development.
7723	* configure, config.in: Re-generated.
7724	* server.c: Include common/sefltest.h.
7725	(captured_main): Handle option --selftest.
7726
77272017-08-09  Yao Qi  <yao.qi@linaro.org>
7728
7729	* configure.srv (srv_i386_regobj): Remove i386-avx.o,
7730	i386-avx-avx512.o, i386-avx-mpx-avx512-pku.o, i386-mpx.o,
7731	i386-avx-mpx.o and i386-mmx.o.
7732	(srv_amd64_regobj): Remove amd64-avx.o, amd64-avx-avx512.o,
7733	amd64-avx-mpx-avx512-pku.o, amd64-mpx.o and amd64-avx-mpx.o.
7734	(srv_i386_xmlfiles): Remove i386/i386-avx.xml,
7735	i386/i386-avx-avx512.xml, i386/i386-avx-mpx-avx512-pku.xml,
7736	i386/i386-mpx.xml, i386/i386-avx-mpx.xml and i386/i386-mmx.xml.
7737	(srv_amd64_xmlfile):i386/amd64-avx.xml, i386/amd64-avx-avx512.xml,
7738	i386/amd64-avx-mpx-avx512-pku.xml, i386/amd64-mpx.xml,
7739	i386/amd64-avx-mpx.xml.
7740
77412017-08-09  Yao Qi  <yao.qi@linaro.org>
7742
7743	* configure.srv (srv_amd64_regobj): Remove x32.o, x32-avx.o
7744	and x32-avx-avx512.o.
7745	(srv_amd64_xmlfiles): Remove i386/x32.xml, i386/x32-avx.xml
7746	i386/x32-avx-avx512.xml.
7747
77482017-07-26  Simon Marchi  <simon.marchi@ericsson.com>
7749
7750	* tracepoint.h (enum class fast_tpoint_collect_result): New
7751	enumeration.
7752	(fast_tracepoint_collecting): Change return type to
7753	fast_tpoint_collect_result.
7754	* tracepoint.c (fast_tracepoint_collecting): Likewise.
7755	* linux-low.h: Include tracepoint.h.
7756	(struct lwp_info) <collecting_fast_tracepoint>: Change type to
7757	fast_tpoint_collect_result.
7758	* linux-low.c (handle_tracepoints): Adjust.
7759	(linux_fast_tracepoint_collecting): Change return type to
7760	fast_tpoint_collect_result.
7761	(maybe_move_out_of_jump_pad, linux_wait_for_event_filtered,
7762	linux_wait_1, stuck_in_jump_pad_callback,
7763	lwp_signal_can_be_delivered, linux_resume_one_lwp_throw,
7764	proceed_one_lwp): Adjust to type change.
7765
77662017-07-10  Yao Qi  <yao.qi@linaro.org>
7767
7768	* linux-x86-low.c (x86_linux_read_description): Re-indent the code.
7769
77702017-06-29  Yao Qi  <yao.qi@linaro.org>
7771
7772	* tdesc.h (struct target_desc) [IN_PROCESS_AGENT] <expedite_regs>:
7773	Remove.
7774	[IN_PROCESS_AGENT] <xmltarget>: Likewise.
7775
77762017-06-20  Simon Marchi  <simon.marchi@ericsson.com>
7777
7778	* Makefile.in (IPA_OBJS): Sort and format one item per line.
7779
77802017-06-20  Sergio Durigan Junior  <sergiodj@redhat.com>
7781
7782	* linux-low.c (linux_create_inferior): Adjust code to access the
7783	environment information via 'gdb_environ' class.
7784	* lynx-low.c (lynx_create_inferior): Likewise.
7785	* server.c (our_environ): Make it an instance of 'gdb_environ'.
7786	(get_environ): Return a pointer to 'our_environ'.
7787	(captured_main): Initialize 'our_environ'.
7788	* server.h (get_environ): Adjust prototype.
7789	* spu-low.c (spu_create_inferior): Adjust code to access the
7790	environment information via 'gdb_environ' class.
7791
77922017-06-17  Simon Marchi  <simon.marchi@ericsson.com>
7793
7794	* linux-low.c (linux_read_memory, linux_write_memory): Remove
7795	usage of "register" keyword.
7796
77972017-06-17  Simon Marchi  <simon.marchi@ericsson.com>
7798
7799	* configure: Re-generate.
7800
78012017-06-17  Simon Marchi  <simon.marchi@ericsson.com>
7802
7803	* configure: Re-generate.
7804
78052017-06-17  Simon Marchi  <simon.marchi@ericsson.com>
7806
7807	* Makefile.in (COMPILE.pre): Add "-x c++".
7808
78092017-06-09  Sergio Durigan Junior  <sergiodj@redhat.com>
7810
7811	* fork-child.c: Conditionally include <signal.h>.
7812
78132017-06-07  Sergio Durigan Junior  <sergiodj@redhat.com>
7814
7815	* server.c (handle_general_set): Handle new packet
7816	"QStartupWithShell".
7817	(handle_query): Add "QStartupWithShell" to the list of supported
7818	packets.
7819	(gdbserver_usage): Add help text explaining the
7820	new "--startup-with-shell" and "--no-startup-with-shell" CLI
7821	options.
7822	(captured_main): Recognize and act upon the presence of the new
7823	CLI options.
7824
78252017-06-07  Sergio Durigan Junior  <sergiodj@redhat.com>
7826	    Pedro Alves  <palves@redhat.com>
7827
7828	* Makefile.in (SFILES): Add "nat/fork-inferior.o".
7829	* configure: Regenerate.
7830	* configure.srv (srv_linux_obj): Add "fork-child.o" and
7831	"fork-inferior.o".
7832	(i[34567]86-*-lynxos*): Likewise.
7833	(spu*-*-*): Likewise.
7834	* fork-child.c: New file.
7835	* linux-low.c: Include "common-inferior.h", "nat/fork-inferior.h"
7836	and "environ.h".
7837	(linux_ptrace_fun): New function.
7838	(linux_create_inferior): Adjust function prototype to reflect
7839	change on "target.h".  Adjust function code to use
7840	"fork_inferior".
7841	(linux_request_interrupt): Delete "signal_pid".
7842	* lynx-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
7843	(lynx_ptrace_fun): New function.
7844	(lynx_create_inferior): Adjust function prototype to reflect
7845	change on "target.h".  Adjust function code to use
7846	"fork_inferior".
7847	* nto-low.c (nto_create_inferior): Adjust function prototype and
7848	code to reflect change on "target.h".  Update comments.
7849	* server.c: Include "common-inferior.h", "nat/fork-inferior.h",
7850	"common-terminal.h" and "environ.h".
7851	(terminal_fd): Moved to fork-child.c.
7852	(old_foreground_pgrp): Likewise.
7853	(restore_old_foreground_pgrp): Likewise.
7854	(last_status): Make it global.
7855	(last_ptid): Likewise.
7856	(our_environ): New variable.
7857	(startup_with_shell): Likewise.
7858	(program_name): Likewise.
7859	(program_argv): Rename to...
7860	(program_args): ...this.
7861	(wrapper_argv): New variable.
7862	(start_inferior): Delete function.
7863	(get_exec_wrapper): New function.
7864	(get_exec_file): Likewise.
7865	(get_environ): Likewise.
7866	(prefork_hook): Likewise.
7867	(post_fork_inferior): Likewise.
7868	(postfork_hook): Likewise.
7869	(postfork_child_hook): Likewise.
7870	(handle_v_run): Update code to deal with arguments coming from the
7871	remote host.  Update calls from "start_inferior" to
7872	"create_inferior".
7873	(captured_main): Likewise.  Initialize environment variable.  Call
7874	"have_job_control".
7875	* server.h (post_fork_inferior): New prototype.
7876	(get_environ): Likewise.
7877	(last_status): Declare.
7878	(last_ptid): Likewise.
7879	(signal_pid): Likewise.
7880	* spu-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
7881	(spu_ptrace_fun): New function.
7882	(spu_create_inferior): Adjust function prototype to reflect change
7883	on "target.h".  Adjust function code to use "fork_inferior".
7884	* target.c (target_terminal_init): New function.
7885	(target_terminal_inferior): Likewise.
7886	(target_terminal_ours): Likewise.
7887	* target.h: Include <vector>.
7888	(struct target_ops) <create_inferior>: Update prototype.
7889	(create_inferior): Update macro.
7890	* utils.c (gdb_flush_out_err): New function.
7891	* win32-low.c (win32_create_inferior): Adjust function prototype
7892	and code to reflect change on "target.h".
7893
78942017-06-07  Sergio Durigan Junior  <sergiodj@redhat.com>
7895
7896	* inferiors.c (switch_to_thread): New function.
7897
78982017-06-07  Sergio Durigan Junior  <sergiodj@redhat.com>
7899
7900	* Makefile.in (SFILE): Add "common/job-control.c".
7901	(OBS): Add "job-control.o".
7902
79032017-05-06  Sergio Durigan Junior  <sergiodj@redhat.com>
7904
7905	* Makefile: Remove "@host_makefile_frag@".
7906
79072017-05-05  Pedro Alves  <palves@redhat.com>
7908
7909	* configure: Regenerate.
7910
79112017-05-03  Sergio Durigan Junior  <sergiodj@redhat.com>
7912
7913	* configure: Regenerate.
7914
79152017-05-02  Simon Marchi  <simon.marchi@polymtl.ca>
7916
7917	* linux-arm-low.c (arm_gdbserver_get_next_pcs): Adjust to
7918	software_single_step change of return type to
7919	std::vector<CORE_ADDR>.
7920	* linux-low.c (install_software_single_step_breakpoints):
7921	Likewise.
7922	* linux-low.h (install_software_single_step_breakpoints):
7923	Likewise.
7924
79252017-04-12  Sergio Durigan Junior  <sergiodj@redhat.com>
7926
7927	* remote-utils.c: Include "gdb_termios.h" instead of
7928	"terminal.h".
7929	* terminal.h: Delete file.
7930
79312017-04-12  Sergio Durigan Junior  <sergiodj@redhat.com>
7932
7933	* server.c: Include <vector>.
7934	<program_argv, wrapper_argv>: Convert to std::vector.
7935	(start_inferior): Rewrite function to use C++.
7936	(handle_v_run): Likewise.  Update code that calculates the argv
7937	based on the vRun packet; use C++.
7938	(captured_main): Likewise.
7939
79402017-04-06  Simon Marchi  <simon.marchi@ericsson.com>
7941
7942	* server.c (handle_v_cont): Initialize thread_resume::thread
7943	with null_ptid.
7944
79452017-04-05  Pedro Alves  <palves@redhat.com>
7946
7947	* configure: Regenerate.
7948
79492017-04-05  Pedro Alves  <palves@redhat.com>
7950
7951	* gdbreplay.c (sync_error): Constify.
7952	* linux-x86-low.c (push_opcode): Constify.
7953
79542017-04-05  Pedro Alves  <palves@redhat.com>
7955
7956	* win32-low.c (get_child_debug_event)
7957	<CREATE_PROCESS_DEBUG_EVENT>: Don't report TARGET_WAITKIND_EXECD.
7958	Report TARGET_WAITKIND_SPURIOUS instead.
7959
79602017-04-05  Pedro Alves  <palves@redhat.com>
7961
7962	* remote-utils.c (remote_prepare, remote_open): Constify.
7963	* remote-utils.h (remote_prepare, remote_open): Constify.
7964	* server.c (captured_main): Constify 'port' handling.
7965
79662017-04-04  Simon Marchi  <simon.marchi@ericsson.com>
7967
7968	* Makefile.in (clean): Clear .deps.
7969
79702017-03-31  Simon Marchi  <simon.marchi@polymtl.ca>
7971
7972	* .gitignore: Remove generated files, replace with wildcard.
7973	* (clean): Replace removal of generated files with wildcard.
7974	(version.c): Replace with...
7975	(version-generated.c): ...this.
7976	(xml-builtin.c): Replace with...
7977	(xml-builtin-generated.c): ...this.
7978	(%-ipa.o: %-generated.c, %.o: %-generated.c): New rules.
7979	(%.c: *regformats*): Replace with...
7980	(%-generated.c: *regformats*): ...this.
7981
79822017-03-27  Max Filippov  <jcmvbkbc@gmail.com>
7983
7984	* linux-xtensa-low.c (regnum::R_THREADPTR): New enum member.
7985	(xtensa_fill_gregset): Call collect_register_by_name for
7986	threadptr register.
7987	(xtensa_store_gregset): Call supply_register_by_name for
7988	threadptr register.
7989
79902017-03-27  Max Filippov  <jcmvbkbc@gmail.com>
7991
7992	* linux-xtensa-low.c (xtensa_fill_gregset): Call collect_register
7993	for all registers in a0_regnum..a0_regnum + C0_NREGS range.
7994	(xtensa_store_gregset): Call supply_register for all registers in
7995	a0_regnum..a0_regnum + C0_NREGS range.
7996
79972017-03-13  Simon Marchi  <simon.marchi@polymtl.ca>
7998
7999	* Makefile.in (%-ipa.o: %-ipa.c): New rule.
8000	(ax-ipa.o: ax.c): Remove.
8001	(linux-i386-ipa.o: linux-i386-ipa.c): Remove.
8002	(linux-amd64-ipa.o: linux-amd64-ipa.c): Remove.
8003	(linux-aarch64-ipa.o: linux-aarch64-ipa.c): Remove.
8004	(linux-s390-ipa.o: linux-s390-ipa.c): Remove.
8005	(linux-ppc-ipa.o: linux-ppc-ipa.c): Remove.
8006
80072017-03-13  Simon Marchi  <simon.marchi@polymtl.ca>
8008
8009	* Makefile.in (%-ipa.o: ../common/%.c): New rule.
8010	(print-utils-ipa.o: ../common/print-utils.c): Remove.
8011	(rsp-low-ipa.o: ../common/rsp-low.c): Remove.
8012	(errors-ipa.o: ../common/errors.c): Remove.
8013	(format-ipa.o: ../common/format.c): Remove.
8014	(common-utils-ipa.o: ../common/common-utils.c): Remove.
8015
80162017-03-13  Simon Marchi  <simon.marchi@polymtl.ca>
8017
8018	* Makefile.in (%-ipa.o: %.c): New rule.
8019	(tracepoint-ipa.o: tracepoint.c): Remove.
8020	(utils-ipa.o: utils.c): Remove.
8021	(remote-utils-ipa.o: remote-utils.c): Remove.
8022	(regcache-ipa.o: regcache.c): Remove.
8023	(i386-linux-ipa.o: i386-linux.c): Remove.
8024	(i386-mmx-linux-ipa.o: i386-mmx-linux.c): Remove.
8025	(i386-avx-linux-ipa.o: i386-avx-linux.c): Remove.
8026	(i386-mpx-linux-ipa.o: i386-mpx-linux.c): Remove.
8027	(i386-avx-mpx-linux-ipa.o: i386-avx-mpx-linux.c): Remove.
8028	(i386-avx-avx512-linux-ipa.o: i386-avx-avx512-linux.c): Remove.
8029	(i386-avx-mpx-avx512-pku-linux-ipa.o: i386-avx-mpx-avx512-pku-linux.c): Remove.
8030	(amd64-linux-ipa.o: amd64-linux.c): Remove.
8031	(amd64-avx-linux-ipa.o: amd64-avx-linux.c): Remove.
8032	(amd64-mpx-linux-ipa.o: amd64-mpx-linux.c): Remove.
8033	(amd64-avx-mpx-linux-ipa.o: amd64-avx-mpx-linux.c): Remove.
8034	(amd64-avx-avx512-linux-ipa.o: amd64-avx-avx512-linux.c): Remove.
8035	(amd64-avx-mpx-avx512-pku-linux-ipa.o: amd64-avx-mpx-avx512-pku-linux.c): Remove.
8036	(aarch64-ipa.o: aarch64.c): Remove.
8037	(s390-linux32-ipa.o: s390-linux32.c): Remove.
8038	(s390-linux32v1-ipa.o: s390-linux32v1.c): Remove.
8039	(s390-linux32v2-ipa.o: s390-linux32v2.c): Remove.
8040	(s390-linux64-ipa.o: s390-linux64.c): Remove.
8041	(s390-linux64v1-ipa.o: s390-linux64v1.c): Remove.
8042	(s390-linux64v2-ipa.o: s390-linux64v2.c): Remove.
8043	(s390-te-linux64-ipa.o: s390-te-linux64.c): Remove.
8044	(s390-vx-linux64-ipa.o: s390-vx-linux64.c): Remove.
8045	(s390-tevx-linux64-ipa.o: s390-tevx-linux64.c): Remove.
8046	(s390x-linux64-ipa.o: s390x-linux64.c): Remove.
8047	(s390x-linux64v1-ipa.o: s390x-linux64v1.c): Remove.
8048	(s390x-linux64v2-ipa.o: s390x-linux64v2.c): Remove.
8049	(s390x-te-linux64-ipa.o: s390x-te-linux64.c): Remove.
8050	(s390x-vx-linux64-ipa.o: s390x-vx-linux64.c): Remove.
8051	(s390x-tevx-linux64-ipa.o: s390x-tevx-linux64.c): Remove.
8052	(powerpc-32l-ipa.o: powerpc-32l.c): Remove.
8053	(powerpc-altivec32l-ipa.o: powerpc-altivec32l.c): Remove.
8054	(powerpc-cell32l-ipa.o: powerpc-cell32l.c): Remove.
8055	(powerpc-vsx32l-ipa.o: powerpc-vsx32l.c): Remove.
8056	(powerpc-isa205-32l-ipa.o: powerpc-isa205-32l.c): Remove.
8057	(powerpc-isa205-altivec32l-ipa.o: powerpc-isa205-altivec32l.c): Remove.
8058	(powerpc-isa205-vsx32l-ipa.o: powerpc-isa205-vsx32l.c): Remove.
8059	(powerpc-e500l-ipa.o: powerpc-e500l.c): Remove.
8060	(powerpc-64l-ipa.o: powerpc-64l.c): Remove.
8061	(powerpc-altivec64l-ipa.o: powerpc-altivec64l.c): Remove.
8062	(powerpc-cell64l-ipa.o: powerpc-cell64l.c): Remove.
8063	(powerpc-vsx64l-ipa.o: powerpc-vsx64l.c): Remove.
8064	(powerpc-isa205-64l-ipa.o: powerpc-isa205-64l.c): Remove.
8065	(powerpc-isa205-altivec64l-ipa.o: powerpc-isa205-altivec64l.c): Remove.
8066	(powerpc-isa205-vsx64l-ipa.o: powerpc-isa205-vsx64l.c): Remove.
8067	(tdesc-ipa.o: tdesc.c): Remove.
8068	(x32-linux-ipa.o: x32-linux.c): Remove.
8069	(x32-avx-linux-ipa.o: x32-avx-linux.c): Remove.
8070	(x32-avx512-linux-ipa.o: x32-avx512-linux.c): Remove.
8071
80722017-03-13  Simon Marchi  <simon.marchi@polymtl.ca>
8073
8074	* Makefile.in (%.o: ../arch/%.c): New rule.
8075	(arm.o: ../arch/arm.c): Remove.
8076	(arm-linux.o: ../arch/arm-linux.c): Remove.
8077	(arm-get-next-pcs.o: ../arch/arm-get-next-pcs.c): Remove.
8078	(aarch64-insn.o: ../arch/aarch64-insn.c): Remove.
8079
80802017-03-13  Simon Marchi  <simon.marchi@polymtl.ca>
8081
8082	* Makefile.in (%.o: ../nat/%.c): New rule.
8083	(x86-dregs.o: ../nat/x86-dregs.c): Remove.
8084	(amd64-linux-siginfo.o: ../nat/amd64-linux-siginfo.c): Remove.
8085	(linux-btrace.o: ../nat/linux-btrace.c): Remove.
8086	(linux-osdata.o: ../nat/linux-osdata.c): Remove.
8087	(linux-procfs.o: ../nat/linux-procfs.c): Remove.
8088	(linux-ptrace.o: ../nat/linux-ptrace.c): Remove.
8089	(linux-waitpid.o: ../nat/linux-waitpid.c): Remove.
8090	(mips-linux-watch.o: ../nat/mips-linux-watch.c): Remove.
8091	(ppc-linux.o: ../nat/ppc-linux.c): Remove.
8092	(linux-personality.o: ../nat/linux-personality.c): Remove.
8093	(aarch64-linux-hw-point.o: ../nat/aarch64-linux-hw-point.c): Remove.
8094	(aarch64-linux.o: ../nat/aarch64-linux.c): Remove.
8095	(x86-linux.o: ../nat/x86-linux.c): Remove.
8096	(x86-linux-dregs.o: ../nat/x86-linux-dregs.c): Remove.
8097	(linux-namespaces.o: ../nat/linux-namespaces.c): Remove.
8098
80992017-03-13  Simon Marchi  <simon.marchi@polymtl.ca>
8100
8101	* Makefile.in (%.o: ../common/%.c): New rule.
8102	(signals.o: ../common/signals.c): Remove.
8103	(print-utils.o: ../common/print-utils.c): Remove.
8104	(rsp-low.o: ../common/rsp-low.c): Remove.
8105	(common-utils.o: ../common/common-utils.c): Remove.
8106	(posix-strerror.o: ../common/posix-strerror.c): Remove.
8107	(mingw-strerror.o: ../common/mingw-strerror.c): Remove.
8108	(vec.o: ../common/vec.c): Remove.
8109	(gdb_vecs.o: ../common/gdb_vecs.c): Remove.
8110	(xml-utils.o: ../common/xml-utils.c): Remove.
8111	(ptid.o: ../common/ptid.c): Remove.
8112	(buffer.o: ../common/buffer.c): Remove.
8113	(format.o: ../common/format.c): Remove.
8114	(filestuff.o: ../common/filestuff.c): Remove.
8115	(agent.o: ../common/agent.c): Remove.
8116	(errors.o: ../common/errors.c): Remove.
8117	(environ.o: ../common/environ.c): Remove.
8118	(common-debug.o: ../common/common-debug.c): Remove.
8119	(cleanups.o: ../common/cleanups.c): Remove.
8120	(common-exceptions.o: ../common/common-exceptions.c): Remove.
8121	(fileio.o: ../common/fileio.c): Remove.
8122	(common-regcache.o: ../common/common-regcache.c): Remove.
8123	(signals-state-save-restore.o: ../common/signals-state-save-restore.c): Remove.
8124	(new-op.o: ../common/new-op.c): Remove.
8125	(btrace-common.o: ../common/btrace-common.c): Remove.
8126
81272017-03-13  Simon Marchi  <simon.marchi@polymtl.ca>
8128
8129	* Makefile.in (%.o: ../target/%.c): New rule.
8130	(waitstatus.o: ../target/waitstatus.c): Remove.
8131
81322017-03-13  Simon Marchi  <simon.marchi@polymtl.ca>
8133
8134	* Makefile.in
8135	(%.c: ../regformats/%.dat,
8136	(%.c: ../regformats/arm/%.dat,
8137	(%.c: ../regformats/i386/%.dat,
8138	(%.c: ../regformats/rs6000/%.dat): New rules.
8139	(aarch64.c): Remove.
8140	(reg-arm.c): Remove.
8141	(arm-with-iwmmxt.c): Remove.
8142	(arm-with-vfpv2.c): Remove.
8143	(arm-with-vfpv3.c): Remove.
8144	(arm-with-neon.c): Remove.
8145	(reg-bfin.c): Remove.
8146	(reg-cris.c): Remove.
8147	(reg-crisv32.c): Remove.
8148	(i386.c): Remove.
8149	(i386-linux.c): Remove.
8150	(i386-avx.c): Remove.
8151	(i386-avx-linux.c): Remove.
8152	(i386-avx-avx512.c): Remove.
8153	(i386-avx-avx512-linux.c): Remove.
8154	(i386-mpx.c): Remove.
8155	(i386-mpx-linux.c): Remove.
8156	(i386-avx-mpx-avx512-pku.c): Remove.
8157	(i386-avx-mpx-avx512-pku-linux.c): Remove.
8158	(i386-avx-mpx.c): Remove.
8159	(i386-avx-mpx-linux.c): Remove.
8160	(i386-mmx.c): Remove.
8161	(i386-mmx-linux.c): Remove.
8162	(reg-ia64.c): Remove.
8163	(reg-m32r.c): Remove.
8164	(reg-m68k.c): Remove.
8165	(reg-cf.c): Remove.
8166	(mips-linux.c): Remove.
8167	(mips-dsp-linux.c): Remove.
8168	(mips64-linux.c): Remove.
8169	(mips64-dsp-linux.c): Remove.
8170	(nios2-linux.c): Remove.
8171	(powerpc-32.c): Remove.
8172	(powerpc-32l.c): Remove.
8173	(powerpc-altivec32l.c): Remove.
8174	(powerpc-cell32l.c): Remove.
8175	(powerpc-vsx32l.c): Remove.
8176	(powerpc-isa205-32l.c): Remove.
8177	(powerpc-isa205-altivec32l.c): Remove.
8178	(powerpc-isa205-vsx32l.c): Remove.
8179	(powerpc-e500l.c): Remove.
8180	(powerpc-64l.c): Remove.
8181	(powerpc-altivec64l.c): Remove.
8182	(powerpc-cell64l.c): Remove.
8183	(powerpc-vsx64l.c): Remove.
8184	(powerpc-isa205-64l.c): Remove.
8185	(powerpc-isa205-altivec64l.c): Remove.
8186	(powerpc-isa205-vsx64l.c): Remove.
8187	(s390-linux32.c): Remove.
8188	(s390-linux32v1.c): Remove.
8189	(s390-linux32v2.c): Remove.
8190	(s390-linux64.c): Remove.
8191	(s390-linux64v1.c): Remove.
8192	(s390-linux64v2.c): Remove.
8193	(s390-te-linux64.c): Remove.
8194	(s390-vx-linux64.c): Remove.
8195	(s390-tevx-linux64.c): Remove.
8196	(s390x-linux64.c): Remove.
8197	(s390x-linux64v1.c): Remove.
8198	(s390x-linux64v2.c): Remove.
8199	(s390x-te-linux64.c): Remove.
8200	(s390x-vx-linux64.c): Remove.
8201	(s390x-tevx-linux64.c): Remove.
8202	(tic6x-c64xp-linux.c): Remove.
8203	(tic6x-c64x-linux.c): Remove.
8204	(tic6x-c62x-linux.c): Remove.
8205	(reg-sh.c): Remove.
8206	(reg-sparc64.c): Remove.
8207	(reg-spu.c): Remove.
8208	(amd64.c): Remove.
8209	(amd64-linux.c): Remove.
8210	(amd64-avx.c): Remove.
8211	(amd64-avx-linux.c): Remove.
8212	(amd64-avx-avx512.c): Remove.
8213	(amd64-avx-avx512-linux.c): Remove.
8214	(amd64-mpx.c): Remove.
8215	(amd64-mpx-linux.c): Remove.
8216	(amd64-avx-mpx-avx512-pku.c): Remove.
8217	(amd64-avx-mpx-avx512-pku-linux.c): Remove.
8218	(amd64-avx-mpx.c): Remove.
8219	(amd64-avx-mpx-linux.c): Remove.
8220	(x32.c): Remove.
8221	(x32-linux.c): Remove.
8222	(x32-avx.c): Remove.
8223	(x32-avx-linux.c): Remove.
8224	(x32-avx-avx512.c): Remove.
8225	(x32-avx-avx512-linux.c): Remove.
8226	(reg-xtensa.c): Remove.
8227	(reg-tilegx.c): Remove.
8228	(reg-tilegx32.c): Remove.
8229
82302017-03-07  Sergio Durigan Junior  <sergiodj@redhat.com>
8231
8232	* Makefile.in (SFILES): Add "common/environ.c".
8233	(OBJS): Add "common/environ.h".
8234
82352017-01-27  Walfred Tedeschi  <walfred.tedeschi@intel.com>
8236
8237	* configure.ac: Check if the fs_base and gs_base members of
8238	`struct user_regs_struct' exist.
8239	* config.in: Regenerated.
8240	* configure: Likewise.
8241
82422017-01-09  Antoine Tremblay  <antoine.tremblay@ericsson.com>
8243
8244	* linux-aarch32-low.c (arm_breakpoint_kind_from_pc): Use
8245	target_read_memory.
8246	* linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer): Likewise.
8247	(get_next_pcs_syscall_next_pc): Likewise.
8248
82492016-12-23  Luis Machado  <lgustavo@codesourcery.com>
8250
8251	* win32-i386-low.c: Fix incorrect reference to a couple source files.
8252	* nto-x86-low.c: Likewise.
8253
82542016-11-30  Simon Marchi  <simon.marchi@polymtl.ca>
8255
8256	* Makefile.in: Include disable-implicit-rules.mk.
8257
82582016-11-23  Pedro Alves  <palves@redhat.com>
8259
8260	* debug.c: Include <chrono> instead of "gdb_sys_time.h".
8261	(debug_vprintf): Use std::chrono::steady_clock instead of
8262	gettimeofday.  Use '.' instead of ':'.
8263	* tracepoint.c: Include <chrono> instead of "gdb_sys_time.h".
8264	(get_timestamp): Use std::chrono::steady_clock instead of
8265	gettimeofday.
8266
82672016-11-22  Simon Marchi  <simon.marchi@polymtl.ca>
8268
8269	* Makefile.in: Fix whitespace formatting.
8270
82712016-11-22  Simon Marchi  <simon.marchi@polymtl.ca>
8272
8273	* Makefile.in (SFILES, OBS): Flatten list and order
8274	alphabetically.
8275
82762016-11-23  Pedro Alves  <palves@redhat.com>
8277
8278	* event-loop.c (handle_file_event): Use warning.
8279	* linux-low.c (linux_resume_one_lwp_throw): Use warning.
8280	* mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
8281	Use warning.
8282
82832016-11-23  Pedro Alves  <palves@redhat.com>
8284
8285	* linux-low.c (check_zombie_leaders): Use debug_printf for debug
8286	output.
8287	* notif.c (handle_notif_ack, notif_event_enque): Likewise.
8288	* remote-utils.c (putpkt_binary_1, readchar, getpkt): Use
8289	debug_printf and debug_flush for debug output.
8290	* server.c (handle_general_set): Likewise.
8291	* thread-db.c (try_thread_db_load): Use debug_printf for debug
8292	output.
8293
82942016-11-17  Simon Marchi  <simon.marchi@polymtl.ca>
8295
8296	* Makefile.in (.c.o): Replace rule with ...
8297	(%.o: %.c): ... this one.
8298
82992016-11-17  Simon Marchi  <simon.marchi@polymtl.ca>
8300
8301	* Makefile.in: Remove @GMAKE_TRUE@ prefixes and removes lines
8302	prefixed with @GMAKE_FALSE@.  Update comment related to non-GNU
8303	make.
8304	* configure.ac: Remove checks for the make program.
8305	* configure: Re-generate.
8306
83072016-10-28  Pedro Alves  <palves@redhat.com>
8308
8309	* Makefile.in (CXX_DIALECT): Get from configure.
8310	(COMPILE.pre, CC_LD): Append $(CXX_DIALECT).
8311	* acinclude.m4: Include ../ax_cxx_compile_stdcxx.m4.
8312	* configure.ac: Call AX_CXX_COMPILE_STDCXX.
8313	* config.in: Regenerate.
8314	* configure: Regenerate.
8315
83162016-10-27  Yao Qi  <yao.qi@linaro.org>
8317
8318	* linux-low.c (linux_supports_range_stepping): Return true if
8319	can_software_single_step return true.
8320
83212016-10-27  Yao Qi  <yao.qi@linaro.org>
8322
8323	* inferiors.c (find_inferior_in_random): New function.
8324	* inferiors.h (find_inferior_in_random): Declare.
8325	* linux-low.c (linux_wait_for_event_filtered): Call
8326	find_inferior_in_random instead of find_inferior.
8327
83282016-10-27  Yao Qi  <yao.qi@linaro.org>
8329
8330	* linux-low.c (linux_wait_1): If single-step breakpoints are
8331	inserted, remove them.
8332
83332016-10-26  Pedro Alves  <palves@redhat.com>
8334
8335	* linux-low.c (handle_extended_wait): Link parent/child fork
8336	threads.
8337	(linux_wait_1): Unlink them.
8338	(linux_set_resume_request): Ignore resume requests for
8339	already-resumed and unhandled fork child threads.
8340	* linux-low.h (struct lwp_info) <fork_relative>: New field.
8341	* server.c (in_queued_stop_replies_ptid, in_queued_stop_replies):
8342	New functions.
8343	(handle_v_requests) <vCont>: Don't call require_running.
8344	* server.h (in_queued_stop_replies): New declaration.
8345
83462016-10-24  Yao Qi  <yao.qi@linaro.org>
8347
8348	PR server/20733
8349	* linux-aarch64-low.c (append_insns): Cast the return value to
8350	'uint32_t *'.
8351
83522016-10-10  Yao Qi  <yao.qi@linaro.org>
8353
8354	* linux-aarch32-low.c (enum arm_breakpoint_kinds): Remove.
8355
83562016-10-06  Sergio Durigan Junior  <sergiodj@redhat.com>
8357
8358	* target.c (target_supports_multi_process): New function, moved
8359	from...
8360	* target.h (target_supports_multi_process): ... here.  Remove
8361	macro.
8362
83632016-10-05  Tom Tromey  <tom@tromey.com>
8364
8365	PR remote/20655:
8366	* tracepoint.c (handle_tracepoint_bkpts): Check
8367	ipa_error_tracepoint, not ipa_stopping_tracepoint.
8368
83692016-10-05  Yao Qi  <yao.qi@linaro.org>
8370
8371	* configure.srv: Update the path of arm-*.xml files.
8372
83732016-10-05  Terry Guo  <terry.guo@arm.com>
8374	    Yao Qi  <yao.qi@linaro.org>
8375
8376	* Makefile.in: Adjust the path of rules.
8377	* configure.srv: Update the path of xml files.
8378	* regformats/arm-with-iwmmxt.dat: Regenerated.
8379	* regformats/arm-with-neon.dat: Likewise.
8380	* regformats/arm-with-vfpv2.dat: Likewise.
8381	* regformats/arm-with-vfpv3.dat Likewise.
8382
83832016-09-30  Yao Qi  <yao.qi@linaro.org>
8384
8385	PR gdbserver/20627
8386	* target.c (target_stop_and_wait): Don't call
8387	target_continue_no_signal, use resume_stop instead.
8388
83892016-09-26  Yao Qi  <yao.qi@linaro.org>
8390
8391	* linux-low.c (linux_wait_1): Call debug_exit.
8392
83932016-09-23  Pedro Alves  <palves@redhat.com>
8394
8395	* Makefile.in (SFILES): Add common/new-op.c.
8396	(OBS): Add common/new-op.o.
8397	(new-op.o): New rule.
8398
83992016-09-21  Simon Marchi  <simon.marchi@ericsson.com>
8400
8401	* .gitinore: Ignore more files.
8402
84032016-09-21  Yao Qi  <yao.qi@linaro.org>
8404
8405	* linux-aarch32-low.c (arm_fill_gregset): Keep bits 20 to
8406	23.
8407
84082016-09-19  Sergio Durigan Junior  <sergiodj@redhat.com>
8409
8410	* server.c (start_inferior): Call target_mourn_inferior instead of
8411	mourn_inferior; pass ptid_t argument to it.
8412	(resume): Likewise.
8413	(handle_target_event): Likewise.
8414	* target.c (target_mourn_inferior): New function.
8415	* target.h (mourn_inferior): Delete macro.
8416
84172016-09-16  Andreas Arnez  <arnez@linux.vnet.ibm.com>
8418
8419	* linux-low.c (lwp_is_stepping): New function.
8420
84212016-09-06  Carl Love  <cel@us.ibm.com>
8422
8423	* server.c (start_inferior):  Fixed comment, requested comment change
8424	didn't get updated correctly.  Removed reference to ptrace () call as
8425	it is only true on Linux systems.
8426
84272016-09-06  Carl Love  <cel@us.ibm.com>
8428
8429	* server.c (start_inferior):  Do not call
8430	function target_post_create_inferior () if the
8431	inferior process has already exited.
8432
84332016-09-05  Pedro Alves  <palves@redhat.com>
8434
8435	* Makefile.in (COMPILER, COMPILER_CFLAGS): Remove.
8436	(COMPILE.pre, CC_LD): Use CXX directly.
8437	(INTERNAL_CFLAGS_BASE): Use CXXFLAGS directly.
8438	* acinclude.m4: Don't include build-with-cxx.m4.
8439	* configure.ac: Remove GDB_AC_BUILD_WITH_CXX call.
8440	* configure: Regenerate.
8441
84422016-09-02  Akash Trehan  <akash.trehan123@gmail.com>
8443
8444	PR gdb/19495
8445	* remote-utils.c (relocate_instruction): Remove redundant strcpy()
8446	call writing data to own_buf.
8447
84482016-09-01  Sergio Durigan Junior  <sergiodj@redhat.com>
8449
8450	* target.c (mywait): Call target_wait instead of
8451	the_target->wait.
8452	(target_wait): New function.
8453
84542016-09-01  Sergio Durigan Junior  <sergiodj@redhat.com>
8455
8456	* server.c (start_inferior): New variable 'ptid'.  Replace calls
8457	to the_target->resume by target_continue{,_no_signal}, depending
8458	on the case.
8459	* target.c (target_stop_and_wait): Call target_continue_no_signal
8460	instead of the_target->resume.
8461	(target_continue): New function.
8462
84632016-08-31  Antoine Tremblay  <antoine.tremblay@ericsson.com>
8464
8465	* linux-low.c (linux_wait_1): Move event switch after unsuspend_lwps.
8466
84672016-08-25  Adhemerval Zanella  <adhemerval.zanella@linaro.org>
8468
8469	PR server/20491
8470	* gdb_proc_service.h (ps_get_thread_area): Remove const from struct
8471	ps_prochandle.
8472	* linux-aarch64-low.c (ps_get_thread_area): Likewise.
8473	* linux-arm-low.c (ps_get_thread_area): Likewise.
8474	* linux-crisv32-low.c (ps_get_thread_area): Likewise.
8475	* linux-m68k-low.c (ps_get_thread_area): Likewise.
8476	* linux-mips-low.c (ps_get_thread_area): Likewise.
8477	* linux-nios2-low.c (ps_get_thread_area): Likewise.
8478	* linux-tic6x-low.c (ps_get_thread_area): Likewise.
8479	* linux-x86-low.c (ps_get_thread_area): Likewise.
8480	* linux-xtensa-low.c (ps_get_thread_area): Likewise.
8481
84822016-08-19  Pedro Alves  <palves@redhat.com>
8483
8484	* linux-x86-low.c (amd64_emit_call): Emit missing call opcode.
8485
84862016-08-19  Pedro Alves  <palves@redhat.com>
8487
8488	* linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Fix
8489	comment.  Use memcpy instead of casting through unsigned long.
8490
84912016-08-19  Pedro Alves  <palves@redhat.com>
8492
8493	* linux-amd64-ipa.c (alloc_jump_pad_buffer) [__ILP32__]: Try
8494	allocating around 0x80000000.
8495
84962016-08-19  Pedro Alves  <palves@redhat.com>
8497
8498	PR gdb/20415
8499	* Makefile.in (x32-linux-ipa.o, x32-avx-linux-ipa.o)
8500	(x32-avx512-linux-ipa.o): New rules.
8501	* configure.ac (x86_64-*-linux*): New x32 check.
8502	* configure.srv (ipa_x32_linux_regobj): New.
8503	(x86_64-*-linux*): Use $ipa_x32_linux_regobj if building for x32.
8504	* linux-amd64-ipa.c (get_ipa_tdesc) [__ILP32__]: Return x32
8505	descriptions.
8506	(initialize_low_tracepoint) [__ILP32__]: Initialize x32
8507	descriptions.
8508	* configure: Regenerate.
8509
85102016-08-09  Pedro Alves  <palves@redhat.com>
8511
8512	PR gdb/18653
8513	* Makefile.in (OBS): Add signals-state-save-restore.o.
8514	(signals-state-save-restore.o): New rule.
8515	* config.in: Regenerate.
8516	* configure: Regenerate.
8517	* linux-low.c: Include "signals-state-save-restore.h".
8518	(linux_create_inferior): Call
8519	restore_original_signals_state.
8520	* server.c: Include "dispositions-save-restore.h".
8521	(captured_main): Call save_original_signals_state.
8522
85232016-08-05  Pedro Alves  <palves@redhat.com>
8524
8525	* configure: Regenerate.
8526
85272016-08-04  Yao Qi  <yao.qi@linaro.org>
8528
8529	* linux-low.c (regsets_fetch_inferior_registers): Check
8530	errno is ESRCH or not.
8531
85322016-08-02  Yao Qi  <yao.qi@linaro.org>
8533
8534	* thread-db.c (struct thread_db) <td_ta_event_getmsg_p>: Remove.
8535	<td_ta_set_event_p, td_ta_event_addr_p>: Remove.
8536	(thread_db_load_search): Update.
8537	(try_thread_db_load_1): Don't look for td_ta_event_addr,
8538	td_ta_set_event and td_ta_event_getmsg.
8539
85402016-07-26  Pedro Alves  <palves@redhat.com>
8541
8542	PR server/20414
8543	* linux-x86-low.c (x86_get_pc, x86_set_pc): Use uint64_t instead
8544	of unsigned long for 64-bit registers and use uint32_t instead of
8545	unsigned int for 32-bit registers.
8546
85472016-07-26  Pedro Alves  <palves@redhat.com>
8548
8549	* linux-x86-low.c (x86_siginfo_fixup): Rename 'native' parameter
8550	to 'ptrace'.
8551
85522016-07-21  Tom Tromey  <tom@tromey.com>
8553
8554	* configure: Rebuild.
8555
85562016-07-21  Yao Qi  <yao.qi@linaro.org>
8557
8558	* mem-break.c (find_gdb_breakpoint): Cast bp to
8559	'struct gdb_breakpoint *' rather than 'gdb_breakpoint *'.
8560
85612016-07-21  Yao Qi  <yao.qi@linaro.org>
8562
8563	* server.c (handle_v_requests): Support s and S actions
8564	if target_supports_software_single_step return true.
8565
85662016-07-21  Yao Qi  <yao.qi@linaro.org>
8567
8568	* linux-low.c (resume_stopped_resumed_lwps): If resume request
8569	is resume_step, call maybe_hw_step.
8570	(linux_wait_1): Stop all threads, remove reinsert breakpoints,
8571	and unstop them.
8572	(linux_resume_one_lwp_throw): Don't assert the thread has reinsert
8573	breakpoints or not.
8574	(proceed_one_lwp): If resume request is resume_step, install
8575	reinsert breakpoints and call maybe_hw_step.
8576
85772016-07-21  Yao Qi  <yao.qi@linaro.org>
8578
8579	* linux-low.c (proceed_one_lwp): Declare.
8580	(linux_resume_one_thread): Remove local variable 'step'.
8581	Lift code enqueue signal.  Call proceed_one_lwp instead of
8582	linux_resume_one_lwp.
8583
85842016-07-21  Yao Qi  <yao.qi@linaro.org>
8585
8586	* linux-low.c (linux_resume_one_thread): Call
8587	enqueue_pending_signal.
8588
85892016-07-21  Yao Qi  <yao.qi@linaro.org>
8590
8591	* gdbthread.h (make_cleanup_restore_current_thread): Declare.
8592	* inferiors.c (do_restore_current_thread_cleanup): New function.
8593	(make_cleanup_restore_current_thread): Likewise.
8594	* linux-low.c (install_software_single_step_breakpoints): Call
8595	make_cleanup_restore_current_thread.  Switch current_thread to
8596	thread.
8597
85982016-07-21  Yao Qi  <yao.qi@linaro.org>
8599
8600	* mem-break.c (struct reinsert_breakpoint) <ptid>: New field.
8601	(set_reinsert_breakpoint): New parameter ptid.  Callers updated.
8602	(clone_one_breakpoint): Likewise.
8603	(delete_reinsert_breakpoints): Change parameter to thread.
8604	Callers updated.
8605	(has_reinsert_breakpoints): Likewise.
8606	(uninsert_reinsert_breakpoints): Likewise.
8607	(reinsert_reinsert_breakpoints): Likewise.
8608	* mem-break.h (set_reinsert_breakpoint): Update declaration.
8609	(delete_reinsert_breakpoints): Likewise.
8610	(reinsert_reinsert_breakpoints): Likewise.
8611	(uninsert_reinsert_breakpoints): Likewise.
8612	(has_reinsert_breakpoints): Likewise.
8613
86142016-07-21  Yao Qi  <yao.qi@linaro.org>
8615
8616	* inferiors.c (get_thread_process): Make parameter const.
8617	* inferiors.h (get_thread_process): Update declaration.
8618	* mem-break.c (clone_all_breakpoints): Remove all parameters.
8619	Add new parameters child_thread and parent_thread.  Callers
8620	updated.
8621	* mem-break.h (clone_all_breakpoints): Update declaration.
8622
86232016-07-21  Yao Qi  <yao.qi@linaro.org>
8624
8625	* mem-break.c (struct breakpoint) <cond_list>: Remove.
8626	<command_list, handler>: Remove.
8627	(struct gdb_breakpoint): New.
8628	(struct other_breakpoint): New.
8629	(struct reinsert_breakpoint): New.
8630	(is_gdb_breakpoint): New function.
8631	(any_persistent_commands): Update command_list if
8632	is_gdb_breakpoint returns true.
8633	(set_breakpoint): Create breakpoints according to their types.
8634	(find_gdb_breakpoint): Return 'struct gdb_breakpoint *'.
8635	(set_gdb_breakpoint_1): Likewise.
8636	(set_gdb_breakpoint): Likewise.
8637	(clear_breakpoint_conditions): Change parameter type to
8638	'struct gdb_breakpoint *'.
8639	(clear_breakpoint_commands): Likewise.
8640	(clear_breakpoint_conditions_and_commands): Likewise.
8641	(add_condition_to_breakpoint): Likewise.
8642	(add_breakpoint_condition): Likewise.
8643	(add_commands_to_breakpoint): Likewise.
8644	(check_breakpoints): Check other_breakpoint.
8645	(clone_one_breakpoint): Clone breakpopint according to its type.
8646	* mem-break.h (struct gdb_breakpoint): Declare.
8647	(set_gdb_breakpoint): Update declaration.
8648	(clear_breakpoint_conditions_and_commands): Likewise.
8649	(add_breakpoint_condition): Likewise.
8650	(add_breakpoint_commands): Likewise.
8651	* server.c (process_point_options): Change parameter type to
8652	'struct gdb_breakpoint *'.
8653
86542016-07-21  Yao Qi  <yao.qi@linaro.org>
8655
8656	* mem-break.c (set_breakpoint_at): Rename it to ...
8657	(set_breakpoint_type_at): ... it.
8658	(set_breakpoint_at): Call set_breakpoint_type_at.
8659	(set_reinsert_breakpoint): Call set_breakpoint_type_at.
8660	* mem-break.h (set_breakpoint_at): Update comments.
8661
86622016-07-12  Chung-Lin Tang  <cltang@codesourcery.com>
8663
8664	* linux-nios2-low.c (nios2_fill_gregset): Add type cast
8665	to buf parameter.
8666	(nios2_store_gregset): Likewise.
8667
86682016-07-01  Pedro Alves  <palves@redhat.com>
8669	    Antoine Tremblay  <antoine.tremblay@ericsson.com>
8670
8671	* linux-low.c: Change interface to take the target lwp_info
8672	pointer directly and return void.  Handle detaching from a zombie
8673	thread.
8674	(linux_detach_lwp_callback): New function.
8675	(linux_detach): Detach from the leader thread after detaching from
8676	the clone threads.
8677
86782016-06-28  Yao Qi  <yao.qi@linaro.org>
8679
8680	* linux-aarch64-low.c (aarch64_ftrace_insn_reloc_b): Use int64_t
8681	for variable new_offset.
8682	(aarch64_ftrace_insn_reloc_b_cond): Likewise.
8683	(aarch64_ftrace_insn_reloc_cb): Likewise.
8684	(aarch64_ftrace_insn_reloc_tb): Likewise.
8685	(aarch64_install_fast_tracepoint_jump_pad): Likewise.  Use
8686	PRIx64 instead of PRIx32.
8687
86882016-06-28  Yao Qi  <yao.qi@linaro.org>
8689
8690	* linux-arm-low.c (arm_get_syscall_trapinfo): New function.
8691	(the_low_target): Install arm_get_syscall_trapinfo.
8692
86932016-06-28  Yao Qi  <yao.qi@linaro.org>
8694
8695	* linux-aarch64-low.c (aarch64_get_syscall_trapinfo): New
8696	function.
8697	(the_low_target): Install aarch64_get_syscall_trapinfo.
8698
86992016-06-28  Yao Qi  <yao.qi@linaro.org>
8700
8701	* linux-low.c (get_syscall_trapinfo): Remove parameter sysret.
8702	Callers updated.
8703	* linux-low.h (struct linux_target_ops) <get_syscall_trapinfo>:
8704	Remove parameter sysno.
8705	* linux-x86-low.c (x86_get_syscall_trapinfo): Remove parameter
8706	sysret.
8707
87082016-06-21  Andreas Arnez  <arnez@linux.vnet.ibm.com>
8709
8710	* linux-s390-low.c (s390_emit_eq_goto): Mark function static.
8711	(s390_emit_ne_goto): Likewise.
8712	(s390_emit_lt_goto): Likewise.
8713	(s390_emit_le_goto): Likewise.
8714	(s390_emit_gt_goto): Likewise.
8715	(s390_emit_ge_goto): Likewise.
8716	(s390x_emit_eq_goto): Likewise.
8717	(s390x_emit_ne_goto): Likewise.
8718	(s390x_emit_lt_goto): Likewise.
8719	(s390x_emit_le_goto): Likewise.
8720	(s390x_emit_gt_goto): Likewise.
8721	(s390x_emit_ge_goto): Likewise.
8722	(s390_emit_ops_impl): Mark variable static.
8723	(s390x_emit_ops): Likewise.
8724
87252016-06-17  Yao Qi  <yao.qi@linaro.org>
8726
8727	* linux-low.c (handle_extended_wait): Call
8728	uninsert_reinsert_breakpoints for the parent process.  Remove
8729	reinsert breakpoints from the child process.  Reinsert them to
8730	the parent process when vfork is done.
8731	* mem-break.c (uninsert_reinsert_breakpoints): New function.
8732	(reinsert_reinsert_breakpoints): New function.
8733	* mem-break.h (uninsert_reinsert_breakpoints): Declare
8734	(reinsert_reinsert_breakpoints): Declare.
8735
87362016-06-17  Yao Qi  <yao.qi@linaro.org>
8737
8738	* linux-low.c (handle_extended_wait): If the parent is doing
8739	step-over, remove the reinsert breakpoints from the forked child.
8740
87412016-06-17  Yao Qi  <yao.qi@linaro.org>
8742
8743	* linux-low.c (unsuspend_all_lwps): Declare.
8744	(linux_low_filter_event): If thread exited, call finish_step_over.
8745	If step-over is finished, unsuspend other threads.
8746
87472016-06-17  Yao Qi  <yao.qi@linaro.org>
8748
8749	* linux-low.c (linux_resume_one_lwp_throw): Assert
8750	has_reinsert_breakpoints returns false.
8751	* mem-break.c (delete_disabled_breakpoints): Assert
8752	bp type isn't reinsert_breakpoint.
8753
87542016-06-17  Yao Qi  <yao.qi@linaro.org>
8755
8756	* linux-low.c (maybe_hw_step): New function.
8757	(linux_resume_one_lwp_throw): Call maybe_hw_step.
8758	(finish_step_over): Switch current_thread to lwp temporarily,
8759	and assert has_reinsert_breakpoints returns true.
8760	(proceed_one_lwp): Call maybe_hw_step.
8761	* mem-break.c (has_reinsert_breakpoints): New function.
8762	* mem-break.h (has_reinsert_breakpoints): Declare.
8763
87642016-06-02  Jon Turney  <jon.turney@dronecode.org.uk>
8765
8766	* win32-low.c (win32_create_inferior): Add pointer casts for C++.
8767
87682016-05-17  Yao Qi  <yao.qi@linaro.org>
8769
8770	* linux-low.c (linux_stabilize_threads): Call unsuspend_all_lwps
8771	instead of find_inferior.
8772
87732016-05-05  Yao Qi  <yao.qi@linaro.org>
8774
8775	* linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer):
8776	Initialize res to zero.
8777
87782016-05-05  Yao Qi  <yao.qi@linaro.org>
8779
8780	* linux-arm-low.c (arm_sigreturn_next_pc): Change type of cpsr
8781	to uint32_t.
8782
87832016-05-04  Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
8784
8785	* spu-low.c (fetch_ppc_register): Cast PowerPC-Linux-specific value
8786	used as first ptrace argument to PTRACE_TYPE_ARG1 for C++.
8787	(fetch_ppc_memory_1, store_ppc_memory_1): Likewise.
8788
87892016-04-28  Par Olsson  <par.olsson@windriver.com>
8790	    Simon Marchi  <simon.marchi@ericsson.com>
8791
8792	* tracepoint.c (write_inferior_int8): New function.
8793	(cmd_qtenable_disable): Write enable flag using
8794	write_inferior_int8.
8795
87962016-04-25  Yao Qi  <yao.qi@linaro.org>
8797
8798	* linux-low.c (lwp_signal_can_be_delivered): Adjust.
8799	(need_step_over_p): Return zero if the LWP has pending signals
8800	can be delivered on software single step target.
8801
88022016-04-25  Yao Qi  <yao.qi@linaro.org>
8803
8804	* linux-low.c (reinsert_raw_breakpoint): If bp->inserted is true
8805	return instead of error.
8806
88072016-04-22  Yao Qi  <yao.qi@linaro.org>
8808
8809	* linux-aarch32-low.c (arm_store_gregset): Clear CPSR bits 20
8810	to 23.
8811
88122016-04-22  Yao Qi  <yao.qi@linaro.org>
8813
8814	* linux-low.c (lwp_signal_can_be_delivered): Don't deliver
8815	signal when stepping over breakpoint with software single
8816	step.
8817
88182016-04-21  Pedro Alves  <palves@redhat.com>
8819
8820	* linux-s390-low.c (s390_collect_ptrace_register)
8821	(s390_supply_ptrace_register, s390_get_hwcap): Use gdb_byte * and
8822	add casts.
8823	(s390_check_regset): Use void * instead of gdb_byte *.
8824
88252016-04-20  Pedro Alves  <palves@redhat.com>
8826
8827	* configure: Renegerate.
8828
88292016-04-20  Yao Qi  <yao.qi@linaro.org>
8830
8831	* linux-aarch32-low.c: Include "arch/arm-linux.h".
8832	(arm_fill_gregset): Use ARM_CPSR_GREGNUM rather than magic
8833	number 16.
8834	(arm_store_gregset): Likewise.
8835
88362016-04-16  Walfred Tedeschi  <walfred.tedeschi@intel.com>
8837
8838	* Makefile.in (clean): Add removal for i386-avx-mpx.c,
8839	i386-avx-mpx-linux.c, amd64-avx-mpx.c and amd64-avx-mpx-linux.c.
8840	(i386-avx-mpx.c, i386-avx-mpx-linux.c, amd64-avx-mpx.c)
8841	(amd64-avx-mpx-linux.c): New rules.
8842	(amd64-avx-mpx-linux-ipa.o, i386-avx-mpx-linux-ipa.o): New rule.
8843	* configure.srv (srv_i386_regobj): Add i386-avx-mpx.o.
8844	(srv_i386_linux_regobj): Add i386-avx-mpx-linux.o.
8845	(srv_amd64_regobj): Add amd64-avx-mpx.o.
8846	(srv_amd64_linux_regobj): Add amd64-avx-mpx-linux.o.
8847	(srv_i386_xmlfiles): Add i386/i386-avx-mpx.xml.
8848	(srv_amd64_xmlfiles): Add i386/amd64-avx-mpx.xml.
8849	(srv_i386_linux_xmlfiles): Add i386/i386-avx-mpx-linux.xml.
8850	(srv_amd64_linux_xmlfiles): Add i386/amd64-avx-mpx-linux.xml.
8851	(ipa_i386_linux_regobj): Add i386-avx-mpx-linux-ipa.o.
8852	(ipa_amd64_linux_regobj): Add amd64-avx-mpx-linux-ipa.o.
8853	* linux-x86-low.c (x86_linux_read_description): Add case for
8854	X86_XSTATE_AVX_MPX_MASK.
8855	(x86_get_ipa_tdesc_idx): Add cases for avx_mpx.
8856	(initialize_low_arch): Call init_registers_amd64_avx_mpx_linux and
8857	init_registers_i386_avx_mpx_linux.
8858	* linux-i386-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
8859	(initialize_low_tracepoint): Call
8860	init_registers_i386_avx_mpx_linux.
8861	* linux-amd64-ipa.c (get_ipa_tdesc):  Add case for avx_mpx.
8862	(initialize_low_tracepoint): Call
8863	init_registers_amd64_avx_mpx_linux.
8864	* linux-x86-tdesc.h (X86_TDESC_AVX_MPX): New enum value.
8865	(init_registers_amd64_avx_mpx_linux, tdesc_amd64_avx_mpx_linux)
8866	(init_registers_i386_avx_mpx_linux, tdesc_i386_avx_mpx_linux): New
8867	declarations.
8868
88692016-04-18  Pedro Alves  <palves@redhat.com>
8870
8871	* configure: Regenerate.
8872
88732016-04-13  Antoine Tremblay  <antoine.tremblay@ericsson.com>
8874
8875	* linux-aarch64-low.c (aarch64_emit_add): Switch x1 and x0.
8876	(aarch64_emit_sub): Likewise.
8877
88782016-04-12  Pedro Alves  <palves@redhat.com>
8879
8880	* utils.c (prepare_to_throw_exception): Delete.
8881
88822016-04-05  Simon Marchi  <simon.marchi@ericsson.com>
8883
8884	* Makefile.in ($(IPA_LIB)): Set SONAME of the IPA lib.
8885
88862016-04-05  Marcin Ko��cielnicki  <koriakin@0x04.net>
8887
8888	* tracepoint.c (getauxval): Move to #ifdef IN_PROCESS_AGENT.
8889
88902016-04-03  Marcin Ko��cielnicki  <koriakin@0x04.net>
8891
8892	* linux-aarch64-ipa.c: Add <elf.h> include.
8893	* linux-ppc-ipa.c: Add <elf.h> include.
8894	* linux-s390-ipa.c: Add <elf.h> include.
8895
88962016-03-31  Marcin Ko��cielnicki  <koriakin@0x04.net>
8897
8898	* tracepoint.c (gdb_collect_ptr): Remove const qualifier.
8899	(get_raw_reg_ptr): Likewise.
8900	(get_trace_state_variable_value_ptr): Likewise.
8901	(set_trace_state_variable_value_ptr): Likewise.
8902	(initialize_tracepoint): Cast alloc_jump_pad_buffer result to
8903	char *.
8904
89052016-03-31  Wei-cheng Wang  <cole945@gmail.com>
8906	    Marcin Ko��cielnicki  <koriakin@0x04.net>
8907
8908	PR/17221
8909	* linux-ppc-low.c (emit_insns): New function.
8910	(__EMIT_ASM, _EMIT_ASM, EMIT_ASM): New macros.
8911	(ppc_emit_prologue): New function.
8912	(ppc_emit_epilogue): New function.
8913	(ppc_emit_add): New function.
8914	(ppc_emit_sub): New function.
8915	(ppc_emit_mul): New function.
8916	(ppc_emit_lsh): New function.
8917	(ppc_emit_rsh_signed): New function.
8918	(ppc_emit_rsh_unsigned): New function.
8919	(ppc_emit_ext): New function.
8920	(ppc_emit_zero_ext): New function.
8921	(ppc_emit_log_not): New function.
8922	(ppc_emit_bit_and): New function.
8923	(ppc_emit_bit_or): New function.
8924	(ppc_emit_bit_xor): New function.
8925	(ppc_emit_bit_not): New function.
8926	(ppc_emit_equal): New function.
8927	(ppc_emit_less_signed): New function.
8928	(ppc_emit_less_unsigned): New function.
8929	(ppc_emit_ref): New function.
8930	(ppc_emit_const): New function.
8931	(ppc_emit_reg): New function.
8932	(ppc_emit_pop): New function.
8933	(ppc_emit_stack_flush): New function.
8934	(ppc_emit_swap): New function.
8935	(ppc_emit_stack_adjust): New function.
8936	(ppc_emit_call): New function.
8937	(ppc_emit_int_call_1): New function.
8938	(ppc_emit_void_call_2): New function.
8939	(ppc_emit_if_goto): New function.
8940	(ppc_emit_goto): New function.
8941	(ppc_emit_eq_goto): New function.
8942	(ppc_emit_ne_goto): New function.
8943	(ppc_emit_lt_goto): New function.
8944	(ppc_emit_le_goto): New function.
8945	(ppc_emit_gt_goto): New function.
8946	(ppc_emit_ge_goto): New function.
8947	(ppc_write_goto_address): New function.
8948	(ppc_emit_ops_impl): New static variable.
8949	(ppc64v1_emit_prologue): New function.
8950	(ppc64v2_emit_prologue): New function.
8951	(ppc64_emit_epilogue): New function.
8952	(ppc64_emit_add): New function.
8953	(ppc64_emit_sub): New function.
8954	(ppc64_emit_mul): New function.
8955	(ppc64_emit_lsh): New function.
8956	(ppc64_emit_rsh_signed): New function.
8957	(ppc64_emit_rsh_unsigned): New function.
8958	(ppc64_emit_ext): New function.
8959	(ppc64_emit_zero_ext): New function.
8960	(ppc64_emit_log_not): New function.
8961	(ppc64_emit_bit_and): New function.
8962	(ppc64_emit_bit_or): New function.
8963	(ppc64_emit_bit_xor): New function.
8964	(ppc64_emit_bit_not): New function.
8965	(ppc64_emit_equal): New function.
8966	(ppc64_emit_less_signed): New function.
8967	(ppc64_emit_less_unsigned): New function.
8968	(ppc64_emit_ref): New function.
8969	(ppc64_emit_const): New function.
8970	(ppc64v1_emit_reg): New function.
8971	(ppc64v2_emit_reg): New function.
8972	(ppc64_emit_pop): New function.
8973	(ppc64_emit_stack_flush): New function.
8974	(ppc64_emit_swap): New function.
8975	(ppc64v1_emit_call): New function.
8976	(ppc64v2_emit_call): New function.
8977	(ppc64v1_emit_int_call_1): New function.
8978	(ppc64v2_emit_int_call_1): New function.
8979	(ppc64v1_emit_void_call_2): New function.
8980	(ppc64v2_emit_void_call_2): New function.
8981	(ppc64_emit_if_goto): New function.
8982	(ppc64_emit_eq_goto): New function.
8983	(ppc64_emit_ne_goto): New function.
8984	(ppc64_emit_lt_goto): New function.
8985	(ppc64_emit_le_goto): New function.
8986	(ppc64_emit_gt_goto): New function.
8987	(ppc64_emit_ge_goto): New function.
8988	(ppc64v1_emit_ops_impl): New static variable.
8989	(ppc64v2_emit_ops_impl): New static variable.
8990	(ppc_emit_ops): New function.
8991	(linux_low_target): Wire in ppc_emit_ops.
8992
89932016-03-31  Wei-cheng Wang  <cole945@gmail.com>
8994	    Marcin Ko��cielnicki  <koriakin@0x04.net>
8995
8996	PR/17221
8997	* Makefile.in: Add powerpc-*-ipa.o
8998	* configure.srv: Add ipa_obj for powerpc*-linux.
8999	* linux-ppc-ipa.c: New file.
9000	* linux-ppc-low.c: Added linux-ppc-tdesc.h, ax.h, tracepoint.h
9001	includes.
9002	(PPC_FIELD): New macro.
9003	(PPC_SEXT): New macro.
9004	(PPC_OP6): New macro.
9005	(PPC_BO): New macro.
9006	(PPC_LI): New macro.
9007	(PPC_BD): New macro.
9008	(init_registers_*): Move prototype to linux-ppc-tdesc.h.
9009	(tdesc_*): Move declaration to linux-ppc-tdesc.h.
9010	(ppc_get_hwcap): Rename to ppc_get_auxv and add type parameter.
9011	(ppc_get_thread_area): New function.
9012	(is_elfv2_inferior): New function.
9013	(gen_ds_form): New function.
9014	(GEN_STD): New macro.
9015	(GEN_STDU): New macro.
9016	(GEN_LD): New macro.
9017	(GEN_LDU): New macro.
9018	(gen_d_form): New function.
9019	(GEN_ADDI): New macro.
9020	(GEN_ADDIS): New macro.
9021	(GEN_LI): New macro.
9022	(GEN_LIS): New macro.
9023	(GEN_ORI): New macro.
9024	(GEN_ORIS): New macro.
9025	(GEN_LWZ): New macro.
9026	(GEN_STW): New macro.
9027	(GEN_STWU): New macro.
9028	(gen_xfx_form): New function.
9029	(GEN_MFSPR): New macro.
9030	(GEN_MTSPR): New macro.
9031	(GEN_MFCR): New macro.
9032	(GEN_MTCR): New macro.
9033	(GEN_SYNC): New macro.
9034	(GEN_LWSYNC): New macro.
9035	(gen_x_form): New function.
9036	(GEN_OR): New macro.
9037	(GEN_MR): New macro.
9038	(GEN_LWARX): New macro.
9039	(GEN_STWCX): New macro.
9040	(GEN_CMPW): New macro.
9041	(gen_md_form): New function.
9042	(GEN_RLDICL): New macro.
9043	(GEN_RLDICR): New macro.
9044	(gen_i_form): New function.
9045	(GEN_B): New macro.
9046	(GEN_BL): New macro.
9047	(gen_b_form): New function.
9048	(GEN_BNE): New macro.
9049	(GEN_LOAD): New macro.
9050	(GEN_STORE): New macro.
9051	(gen_limm): New function.
9052	(gen_atomic_xchg): New function.
9053	(gen_call): New function.
9054	(ppc_relocate_instruction): New function.
9055	(ppc_install_fast_tracepoint_jump_pad): New function.
9056	(ppc_get_min_fast_tracepoint_insn_len): New function.
9057	(ppc_get_ipa_tdesc_idx): New function.
9058	(the_low_target): Wire in the new functions.
9059	(initialize_low_arch) [!__powerpc64__]: Don'it initialize 64-bit
9060	tdescs.
9061	* linux-ppc-tdesc.h: New file.
9062
90632016-03-31  Marcin Ko��cielnicki  <koriakin@0x04.net>
9064
9065	* linux-aarch64-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
9066	(alloc_jump_pad_buffer): New function.
9067	* linux-amd64-ipa.c: Add <sys/mman.h> include.
9068	(alloc_jump_pad_buffer): New function.
9069	* linux-i386-ipa.c (alloc_jump_pad_buffer): New function.
9070	* linux-s390-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
9071	(alloc_jump_pad_buffer): New function.
9072	* tracepoint.c (getauxval) [!HAVE_GETAUXVAL]: New function.
9073	(initialize_tracepoint): Delegate to alloc_jump_pad_buffer.
9074	* tracepoint.h (alloc_jump_pad_buffer): New prototype.
9075	(getauxval) [!HAVE_GETAUXVAL]: New prototype.
9076
90772016-03-30  Marcin Ko��cielnicki  <koriakin@0x04.net>
9078
9079	* linux-aarch64-ipa.c: Rename gdb_agent_get_raw_reg to get_raw_reg.
9080	* linux-amd64-ipa.c: Likewise.
9081	* linux-i386-ipa.c: Likewise.
9082	* linux-s390-ipa.c: Likewise.
9083	* tracepoint.c: IPA-export gdb_collect_ptr instead of gdb_collect,
9084	ditto for get_raw_reg_ptr, get_trace_state_variable_value_ptr,
9085	set_trace_state_variable_value_ptr.
9086	(struct ipa_sym_addresses): Likewise.
9087	(symbol_list): Likewise.
9088	(install_fast_tracepoint): Dereference gdb_collect_ptr instead of
9089	accessing gdb_collect directly.
9090	(gdb_collect_ptr_type): New typedef.
9091	(get_raw_reg_ptr_type): New typedef.
9092	(get_trace_state_variable_value_ptr_type): New typedef.
9093	(set_trace_state_variable_value_ptr_type): New typedef.
9094	(gdb_collect_ptr): New global.
9095	(get_raw_reg_ptr): New global.
9096	(get_trace_state_variable_value_ptr): New global.
9097	(set_trace_state_variable_value_ptr): New global.
9098	(get_raw_reg_func_addr): Dereference get_raw_reg_ptr instead of
9099	accessing get_raw_reg directly.
9100	(get_get_tsv_func_addr): Likewise for
9101	get_trace_state_variable_value_ptr.
9102	(get_set_tsv_func_addr): Likewise for
9103	set_trace_state_variable_value_ptr.
9104	* tracepoint.h: Rename gdb_agent_get_raw_reg to get_raw_reg.
9105
91062016-03-30  Simon Marchi  <simon.marchi@ericsson.com>
9107
9108	* tracepoint.c (cmd_qtenable_disable): Remove whitespace.
9109
91102016-03-30  Marcin Ko��cielnicki  <koriakin@0x04.net>
9111
9112	* remote-utils.c (look_up_one_symbol): Remove own_buf, handle 'v'
9113	packets.
9114	(relocate_instruction): Remove own_buf.
9115	* server.c (own_buf): Make global.
9116	(handle_v_requests): Make global.
9117	* server.h (own_buf): New declaration.
9118	(handle_v_requests): New prototype.
9119
91202016-03-29  Marcin Ko��cielnicki  <koriakin@0x04.net>
9121
9122	PR 18377
9123	* linux-s390-low.c (add_insns): New function.
9124	(s390_emit_prologue): New function.
9125	(s390_emit_epilogue): New function.
9126	(s390_emit_add): New function.
9127	(s390_emit_sub): New function.
9128	(s390_emit_mul): New function.
9129	(s390_emit_lsh): New function.
9130	(s390_emit_rsh_signed): New function.
9131	(s390_emit_rsh_unsigned): New function.
9132	(s390_emit_ext): New function.
9133	(s390_emit_log_not): New function.
9134	(s390_emit_bit_and): New function.
9135	(s390_emit_bit_or): New function.
9136	(s390_emit_bit_xor): New function.
9137	(s390_emit_bit_not): New function.
9138	(s390_emit_equal): New function.
9139	(s390_emit_less_signed): New function.
9140	(s390_emit_less_unsigned): New function.
9141	(s390_emit_ref): New function.
9142	(s390_emit_if_goto): New function.
9143	(s390_emit_goto): New function.
9144	(s390_write_goto_address): New function.
9145	(s390_emit_litpool): New function.
9146	(s390_emit_const): New function.
9147	(s390_emit_call): New function.
9148	(s390_emit_reg): New function.
9149	(s390_emit_pop): New function.
9150	(s390_emit_stack_flush): New function.
9151	(s390_emit_zero_ext): New function.
9152	(s390_emit_swap): New function.
9153	(s390_emit_stack_adjust): New function.
9154	(s390_emit_set_r2): New function.
9155	(s390_emit_int_call_1): New function.
9156	(s390_emit_void_call_2): New function.
9157	(s390_emit_eq_goto): New function.
9158	(s390_emit_ne_goto): New function.
9159	(s390_emit_lt_goto): New function.
9160	(s390_emit_le_goto): New function.
9161	(s390_emit_gt_goto): New function.
9162	(s390_emit_ge_goto): New function.
9163	(s390x_emit_prologue): New function.
9164	(s390x_emit_epilogue): New function.
9165	(s390x_emit_add): New function.
9166	(s390x_emit_sub): New function.
9167	(s390x_emit_mul): New function.
9168	(s390x_emit_lsh): New function.
9169	(s390x_emit_rsh_signed): New function.
9170	(s390x_emit_rsh_unsigned): New function.
9171	(s390x_emit_ext): New function.
9172	(s390x_emit_log_not): New function.
9173	(s390x_emit_bit_and): New function.
9174	(s390x_emit_bit_or): New function.
9175	(s390x_emit_bit_xor): New function.
9176	(s390x_emit_bit_not): New function.
9177	(s390x_emit_equal): New function.
9178	(s390x_emit_less_signed): New function.
9179	(s390x_emit_less_unsigned): New function.
9180	(s390x_emit_ref): New function.
9181	(s390x_emit_if_goto): New function.
9182	(s390x_emit_const): New function.
9183	(s390x_emit_call): New function.
9184	(s390x_emit_reg): New function.
9185	(s390x_emit_pop): New function.
9186	(s390x_emit_stack_flush): New function.
9187	(s390x_emit_zero_ext): New function.
9188	(s390x_emit_swap): New function.
9189	(s390x_emit_stack_adjust): New function.
9190	(s390x_emit_int_call_1): New function.
9191	(s390x_emit_void_call_2): New function.
9192	(s390x_emit_eq_goto): New function.
9193	(s390x_emit_ne_goto): New function.
9194	(s390x_emit_lt_goto): New function.
9195	(s390x_emit_le_goto): New function.
9196	(s390x_emit_gt_goto): New function.
9197	(s390x_emit_ge_goto): New function.
9198	(s390_emit_ops): New function.
9199	(struct linux_target_ops): Fill in emit_ops hook.
9200
92012016-03-29  Marcin Ko��cielnicki  <koriakin@0x04.net>
9202
9203	PR 18377
9204	* Makefile.in: Add s390 IPA files.
9205	* configure.srv: Build IPA for s390.
9206	* linux-s390-ipa.c: New file.
9207	* linux-s390-low.c: New includes - inttypes.h and linux-s390-tdesc.h.
9208	(init_registers_s390_linux32): Move declaration to linux-s390-tdesc.h.
9209	(tdesc_s390_linux32): Likewise.
9210	(init_registers_s390_linux32v1): Likewise.
9211	(tdesc_s390_linux32v1): Likewise.
9212	(init_registers_s390_linux32v2): Likewise.
9213	(tdesc_s390_linux32v2): Likewise.
9214	(init_registers_s390_linux64): Likewise.
9215	(tdesc_s390_linux64): Likewise.
9216	(init_registers_s390_linux64v1): Likewise.
9217	(tdesc_s390_linux64v1): Likewise.
9218	(init_registers_s390_linux64v2): Likewise.
9219	(tdesc_s390_linux64v2): Likewise.
9220	(init_registers_s390_te_linux64): Likewise.
9221	(tdesc_s390_te_linux64): Likewise.
9222	(init_registers_s390_vx_linux64): Likewise.
9223	(tdesc_s390_vx_linux64): Likewise.
9224	(init_registers_s390_tevx_linux64): Likewise.
9225	(tdesc_s390_tevx_linux64): Likewise.
9226	(init_registers_s390x_linux64): Likewise.
9227	(tdesc_s390x_linux64): Likewise.
9228	(init_registers_s390x_linux64v1): Likewise.
9229	(tdesc_s390x_linux64v1): Likewise.
9230	(init_registers_s390x_linux64v2): Likewise.
9231	(tdesc_s390x_linux64v2): Likewise.
9232	(init_registers_s390x_te_linux64): Likewise.
9233	(tdesc_s390x_te_linux64): Likewise.
9234	(init_registers_s390x_vx_linux64): Likewise.
9235	(tdesc_s390x_vx_linux64): Likewise.
9236	(init_registers_s390x_tevx_linux64): Likewise.
9237	(tdesc_s390x_tevx_linux64): Likewise.
9238	(have_hwcap_s390_vx): New static variable.
9239	(s390_arch_setup): Fill have_hwcap_s390_vx.
9240	(s390_get_thread_area): New function.
9241	(s390_ft_entry_gpr_esa): New const.
9242	(s390_ft_entry_gpr_zarch): New const.
9243	(s390_ft_entry_misc): New const.
9244	(s390_ft_entry_fr): New const.
9245	(s390_ft_entry_vr): New const.
9246	(s390_ft_main_31): New const.
9247	(s390_ft_main_64): New const.
9248	(s390_ft_exit_fr): New const.
9249	(s390_ft_exit_vr): New const.
9250	(s390_ft_exit_misc): New const.
9251	(s390_ft_exit_gpr_esa): New const.
9252	(s390_ft_exit_gpr_zarch): New const.
9253	(append_insns): New function.
9254	(s390_relocate_instruction): New function.
9255	(s390_install_fast_tracepoint_jump_pad): New function.
9256	(s390_get_min_fast_tracepoint_insn_len): New function.
9257	(s390_get_ipa_tdesc_idx): New function.
9258	(struct linux_target_ops): Wire in the above functions.
9259	(initialize_low_arch) [!__s390x__]: Don't initialize s390x tdescs.
9260	* linux-s390-tdesc.h: New file.
9261
92622016-03-29  Marcin Ko��cielnicki  <koriakin@0x04.net>
9263
9264	* linux-s390-low.c (s390_supports_tracepoints): New function.
9265	(struct linux_target_ops): Fill supports_tracepoints hook.
9266
92672016-03-18  Yao Qi  <yao.qi@linaro.org>
9268
9269	* linux-low.c (lwp_signal_can_be_delivered): New function.
9270	(linux_resume_one_lwp_throw): Use lwp_signal_can_be_delivered.
9271
92722016-03-18  Yao Qi  <yao.qi@linaro.org>
9273
9274	* linux-low.c (linux_resume_one_lwp_throw): Set 'signal' to
9275	0 if signal is enqueued.  Remove 'signal' from one debugging
9276	message.  Move one debugging message to some lines below.
9277	Remove code setting 'signal' to 0.
9278
92792016-03-18  Yao Qi  <yao.qi@linaro.org>
9280
9281	* linux-low.c (linux_low_filter_event): Remove redundant
9282	WIFSTOPPED check together with linux_wstatus_maybe_breakpoint.
9283
92842016-03-09  Marcin Ko��cielnicki  <koriakin@0x04.net>
9285
9286	* linux-ppc-low.c (ppc_supports_tracepoints): New function.
9287	(struct linux_target_ops): Wire in the above.
9288
92892016-03-03  Yao Qi  <yao.qi@linaro.org>
9290
9291	* linux-low.c: Update comments to start_step_over.
9292
92932016-03-03  Yao Qi  <yao.qi@linaro.org>
9294
9295	PR server/19736
9296	* linux-low.c (handle_extended_wait): Set child suspended
9297	if event_lwp->bp_reinsert isn't zero.
9298
92992016-03-02  Yao Qi  <yao.qi@linaro.org>
9300
9301	* linux-low.c (linux_resume_one_lwp_throw): Replace code with
9302	enqueue_pending_signal.
9303
93042016-03-02  Marcin Ko��cielnicki  <koriakin@0x04.net>
9305
9306	* tracepoint.c (cmd_qtstart): Only set ipa_tdesc_idx if agent
9307	is actually loaded.
9308
93092016-02-25  Marcin Ko��cielnicki  <koriakin@0x04.net>
9310
9311	* linux-s390-low.c (s390_num_regs_3264): Define on 31-bit too.
9312	(s390_regmap_3264) [!__s390x__]: New global.
9313	(s390_collect_ptrace_register): Skip map entries containing -1.
9314	(s390_supply_ptrace_register): Ditto.
9315	(s390_fill_gprs_high): New function.
9316	(s390_store_gprs_high): New function.
9317	(s390_regsets): Add NT_S390_HIGH_GPRS.
9318	(s390_get_hwcap): Enable on 31-bit.
9319	(have_hwcap_s390_high_gprs): Enable on 31-bit.
9320	(s390_arch_setup): Enable detection of high GPRs, TDB, VX on 31-bit.
9321	Detect NT_S390_HIGH_GPRS.
9322	(s390_usrregs_info_3264): Enable on 31-bit.
9323	(s390_regs_info): Enable regs_info_3264 on 31-bit.
9324	(initialize_low_arch): Initialize s390_regsets_info_3264 on 31-bit.
9325
93262016-02-25  Marcin Ko��cielnicki  <koriakin@0x04.net>
9327
9328	PR gdb/13808
9329	* Makefile.in: Add i386-*-linux-ipa.o and amd64-*-linux-ipa.o.
9330	* configure.srv: Ditto.
9331	* linux-aarch64-ipa.c (get_ipa_tdesc): New function.
9332	(initialize_low_tracepoint): Remove ipa_tdesc assignment.
9333	* linux-amd64-ipa.c: Add "linux-x86-tdesc.h" include.
9334	(init_registers_amd64_linux): Remove prototype.
9335	(tdesc_amd64_linux): Remove declaration.
9336	(get_ipa_tdesc): New function.
9337	(initialize_low_tracepoint): Remove ipa_tdesc assignment,
9338	initialize remaining tdescs.
9339	* linux-i386-ipa.c: Add "linux-x86-tdesc.h" include.
9340	(init_registers_i386_linux): Remove prototype.
9341	(tdesc_i386_linux): Remove declaration.
9342	(get_ipa_tdesc): New function.
9343	(initialize_low_tracepoint): Remove ipa_tdesc assignment,
9344	initialize remaining tdescs.
9345	* linux-low.c (linux_get_ipa_tdesc_idx): New function.
9346	(linux_target_ops): wire in linux_get_ipa_tdesc_idx.
9347	* linux-low.h (struct linux_target_ops): Add get_ipa_tdesc_idx.
9348	* linux-x86-low.c: Move tdesc declarations to linux-x86-tdesc.h.
9349	(x86_get_ipa_tdesc_idx): New function.
9350	(the_low_target): Wire in x86_get_ipa_tdesc_idx.
9351	* linux-x86-tdesc.h: New file.
9352	* target.h (struct target_ops): Add get_ipa_tdesc_idx.
9353	(target_get_ipa_tdesc_idx): New macro.
9354	* tracepoint.c (ipa_tdesc_idx): New macro.
9355	(struct ipa_sym_addresses): Add addr_ipa_tdesc_idx.
9356	(symbol_list): Add ipa_tdesc_idx.
9357	(cmd_qtstart): Write ipa_tdesc_idx in the target.
9358	(ipa_tdesc): Remove.
9359	(ipa_tdesc_idx): New variable.
9360	(get_context_regcache): Use get_ipa_tdesc.
9361	(gdb_collect): Ditto.
9362	(gdb_probe): Ditto.
9363	* tracepoint.h (get_ipa_tdesc): New prototype.
9364	(ipa_tdesc): Remove.
9365
93662016-02-24  Pedro Alves  <palves@redhat.com>
9367
9368	* linux-low.c (check_stopped_by_breakpoint): Rename to ...
9369	(save_stop_reason): ... this.  Use GDB_ARCH_IS_TRAP_HWBKPT and
9370	handle ambiguous GDB_ARCH_IS_TRAP_BRKPT / GDB_ARCH_IS_TRAP_HWBKPT.
9371	Factor out common code between the USE_SIGTRAP_SIGINFO and
9372	!USE_SIGTRAP_SIGINFO blocks.
9373	(linux_low_filter_event): Call save_stop_reason instead of
9374	check_stopped_by_breakpoint and check_stopped_by_watchpoint.
9375	Update comments.
9376	(linux_wait_1): Update comments.
9377
93782016-02-24  Wei-cheng Wang  <cole945@gmail.com>
9379
9380	* linux-ppc-low.c (ppc_supports_z_point_type): New function:
9381	(ppc_insert_point, ppc_remove_point): Insert/remove z-packet breakpoints.
9382	(ppc64_emit_ops_vector): Add target ops - ppc_supports_z_point_type,
9383	ppc_insert_point, ppc_remove_point.
9384
93852016-02-17  Marcin Ko��cielnicki  <koriakin@0x04.net>
9386
9387	* linux-s390-low.c (s390_supports_z_point_type): New function.
9388	(struct linux_target_ops): Wire s390_supports_z_point_type in.
9389
93902016-02-16  Yao Qi  <yao.qi@linaro.org>
9391
9392	* linux-arm-low.c (get_next_pcs_syscall_next_pc): Remove argument
9393	PC.  Get pc from regcache_read_pc.
9394
93952016-02-12  Yao Qi  <yao.qi@linaro.org>
9396
9397	* linux-aarch64-low.c (aarch64_get_pc): Call linux_get_pc_64bit
9398	or linux_get_pc_32bit.
9399	(aarch64_set_pc): Call linux_set_pc_64bit or linux_set_pc_32bit.
9400
94012016-02-12  Yao Qi  <yao.qi@linaro.org>
9402
9403	* linux-arm-low.c (get_next_pcs_ops): Initialize it with
9404	arm_linux_get_next_pcs_fixup.
9405
94062016-02-12  Marcin Ko��cielnicki  <koriakin@0x04.net>
9407
9408	* tracepoint.c (x_tracepoint_action_download): Change
9409	write_inferior_data_ptr to write_inferior_data_pointer.
9410	(cmd_qtstart): Likewise.
9411	(write_inferior_data_ptr): Remove.
9412	(download_agent_expr): Change write_inferior_data_ptr to
9413	write_inferior_data_pointer.
9414	(download_tracepoint_1): Likewise.
9415	(download_tracepoint): Likewise.
9416	(download_trace_state_variables): Likewise.
9417
94182016-02-11  Wei-cheng Wang  <cole945@gmail.com>
9419	    Marcin Ko��cielnicki  <koriakin@0x04.net>
9420
9421	* tracepoint.c (struct tracepoint_action_ops): Remove.
9422	(struct tracepoint_action): Remove ops.
9423	(m_tracepoint_action_download, r_tracepoint_action_download)
9424	(x_tracepoint_action_download, l_tracepoint_action_download): Adjust
9425	size and offset accordingly.
9426	(m_tracepoint_action_ops, r_tracepoint_action_ops)
9427	(x_tracepoint_action_ops, l_tracepoint_action_ops): Remove.
9428	(tracepoint_action_send, tracepoint_action_download): New functions.
9429	Helpers for trace action handlers.
9430	(add_tracepoint_action): Remove setup actions ops.
9431	(download_tracepoint_1, tracepoint_send_agent): Call helper functions.
9432
94332016-02-10  Yao Qi  <yao.qi@linaro.org>
9434
9435	* regcache.c (regcache_raw_read_unsigned): Clear *VAL.
9436
94372016-02-09  Simon Marchi  <simon.marchi@ericsson.com>
9438
9439	* configure.ac: Use AC_CONFIG_FILES instead of passing arguments
9440	to AC_OUTPUT.
9441	* configure: Regenerate.
9442
94432016-02-09  Simon Marchi  <simon.marchi@ericsson.com>
9444
9445	* linux-aarch64-low.c (aarch64_linux_siginfo_fixup): Change
9446	void * to gdb_byte *.
9447	* linux-low.c (siginfo_fixup): Likewise.
9448	(linux_xfer_siginfo): Likewise.
9449	* linux-low.h (struct linux_target_ops) <siginfo_fixup>:
9450	Likewise.
9451	* linux-x86-low.c (x86_siginfo_fixup): Likewise.
9452
94532016-02-02  Walfred Tedeschi  <walfred.tedeschi@intel.com>
9454
9455	* configure.srv (x86_64-*-linux*): Add amd64-linux-siginfo.o
9456	to srv_tgtobj.
9457	(i[34567]86-*-linux*): Add amd64-linux-siginfo.o
9458	to srv_tgtobj.
9459	* linux-x86-low.c [__x86_64__]: Include
9460	"nat/amd64-linux-siginfo.h".
9461	(compat_siginfo_from_siginfo, siginfo_from_compat_siginfo)
9462	(compat_x32_siginfo_from_siginfo, siginfo_from_compat_x32_siginfo)
9463	(compat_timeval, compat_sigval, compat_x32_clock, cpt_si_pid)
9464	(cpt_si_uid, cpt_si_timerid, cpt_si_overrun, cpt_si_status)
9465	(cpt_si_utime, cpt_si_stime, cpt_si_ptr, cpt_si_addr, cpt_si_band)
9466	(cpt_si_fd, si_timerid, si_overrun): Move from
9467	nat/amd64-linux-siginfo.c.
9468	* Makefile.in (amd64-linux-siginfo.o:): New rule.
9469
94702016-01-28  Simon Marchi  <simon.marchi@ericsson.com>
9471
9472	* server.c (skip_to_semicolon):  Remove.
9473	(process_point_options): Use strchrnul instead of
9474	skip_to_semicolon.
9475
94762016-01-26  Yao Qi  <yao.qi@linaro.org>
9477
9478	* linux-arm-low.c (arm_gdbserver_get_next_pcs): Remove argument pc.
9479	* linux-low.c (install_software_single_step_breakpoints): Don't
9480	call regcache_read_pc.
9481	* linux-low.h (struct linux_target_ops) <get_next_pcs>: Remove
9482	argument pc.
9483
94842016-01-26  Yao Qi  <yao.qi@linaro.org>
9485
9486	* linux-low.c (install_software_single_step_breakpoints): Call
9487	regcache_read_pc instead of get_pc.
9488
94892016-01-26  Yao Qi  <yao.qi@linaro.org>
9490
9491	* remote-utils.c (remote_close) [!USE_WIN32API]: Ignore SIGIO.
9492	(unblock_async_io): Rename to ...
9493	(block_unblock_async_io): ... it.  New function.
9494	(enable_async_io): Don't install SIGIO handler.  Unblock it
9495	instead.
9496	(disable_async_io): Don't ignore SIGIO.  Block it instead.
9497	(initialize_async_io): Install SIGIO handler.  Don't call
9498	unblock_async_io.
9499
95002016-01-26  Yao Qi  <yao.qi@linaro.org>
9501
9502	* remote-utils.c (getpkt): If the buffer isn't empty, and the
9503	first character is '\003', call *the_target->request_interrupt.
9504
95052016-01-25  Yao Qi  <yao.qi@linaro.org>
9506
9507	* remote-utils.c (new_thread_notify): Remove.
9508	(dead_thread_notify): Likewise.
9509	* remote-utils.h (new_thread_notify): Remove declaration.
9510	(dead_thread_notify): Likewise.
9511
95122016-01-23  Marcin Ko��cielnicki  <koriakin@0x04.net>
9513
9514	* gdb.trace/pending.exp: Fix expected message on continue.
9515
95162016-01-22  Marcin Ko��cielnicki  <koriakin@0x04.net>
9517
9518	* tracepoint.c (write_inferior_data_ptr): Cast to uintptr_t, so that
9519	it works properly on big-endian machines where sizeof (CORE_ADDR)
9520	!= sizeof (void *).
9521
95222016-01-21  Pedro Alves  <palves@redhat.com>
9523
9524	* Makefile.in (COMPILER_CFLAGS, CXXFLAGS): New.
9525	(INTERNAL_CFLAGS_BASE): Use COMPILER_CFLAGS instead of CFLAGS.
9526	* configure: Regenerate.
9527
95282016-01-21  Yao Qi  <yao.qi@linaro.org>
9529
9530	* linux-arm-low.c (arm_sigreturn_next_pc): Add parameter
9531	is_thumb and set it according to CPSR saved on the stack.
9532	(get_next_pcs_syscall_next_pc): Pass is_thumb to
9533	arm_sigreturn_next_pc.
9534
95352016-01-18  Yao Qi  <yao.qi@linaro.org>
9536
9537	* linux-low.c (linux_set_pc_64bit): New function.
9538	(linux_get_pc_64bit): New function.
9539	* linux-low.h (linux_set_pc_64bit, linux_get_pc_64bit):
9540	Declare.
9541	* linux-sparc-low.c (debug_threads): Remove declaration.
9542	(sparc_get_pc): Remove.
9543	(the_low_target): Use linux_get_pc_64bit instead of
9544	sparc_get_pc.
9545	* linux-tile-low.c (tile_get_pc, tile_set_pc): Remove.
9546	(the_low_target): Use linux_get_pc_64bit and
9547	linux_set_pc_64bit.
9548
95492016-01-18  Yao Qi  <yao.qi@linaro.org>
9550
9551	* linux-arm-low.c (debug_threads): Remove declaration.
9552	(arm_get_pc, arm_set_pc): Remove.
9553	(the_low_target): Use linux_get_pc_32bit and
9554	linux_set_pc_32bit.
9555	* linux-bfin-low.c (bfin_get_pc, bfin_set_pc): Remove.
9556	(the_low_target): Use linux_get_pc_32bit and
9557	linux_set_pc_32bit.
9558	* linux-cris-low.c (debug_threads): Remove declaration.
9559	(cris_get_pc, cris_set_pc,): Remove.
9560	(the_low_target): Use linux_get_pc_32bit and
9561	linux_set_pc_32bit.
9562	* linux-crisv32-low.c (debug_threads): Remove declaration.
9563	(cris_get_pc, cris_set_pc): Remove.
9564	(the_low_target): Use linux_get_pc_32bit and
9565	linux_set_pc_32bit.
9566	* linux-low.c: Include inttypes.h.
9567	(linux_get_pc_32bit, linux_set_pc_32bit): New functions.
9568	* linux-low.h (linux_get_pc_32bit, linux_set_pc_32bit): Declare.
9569	* linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Remove.
9570	(the_low_target): Use linux_get_pc_32bit and
9571	linux_set_pc_32bit.
9572	* linux-m68k-low.c (m68k_get_pc, m68k_set_pc): Remove.
9573	(the_low_target): Use linux_get_pc_32bit and
9574	linux_set_pc_32bit.
9575	* linux-nios2-low.c (nios2_get_pc, nios2_set_pc): Remove.
9576	(the_low_target): Use linux_get_pc_32bit and
9577	linux_set_pc_32bit.
9578	* linux-sh-low.c (sh_get_pc, sh_set_pc): Remove.
9579	(the_low_target): Use linux_get_pc_32bit and
9580	linux_set_pc_32bit.
9581	* linux-xtensa-low.c (xtensa_get_pc, xtensa_set_pc): Remove.
9582	(the_low_target): Use linux_get_pc_32bit and
9583	linux_set_pc_32bit.
9584
95852016-01-18  Gary Benson  <gbenson@redhat.com>
9586
9587	* configure.ac (AC_FUNC_FORK): New check.
9588	* config.in: Regenerate.
9589	* configure: Likewise.
9590
95912016-01-14  Yao Qi  <yao.qi@linaro.org>
9592
9593	* linux-aarch32-low.c (thumb2_breakpoint): Make it static.
9594	* linux-aarch32-low.h (thumb2_breakpoint): Remove declaration.
9595	* linux-arm-low.c (arm_gdbserver_get_next_pcs): Pass 1 to
9596	arm_get_next_pcs_ctor.
9597
95982016-01-12  Josh Stone  <jistone@redhat.com>
9599	    Philippe Waroquiers  <philippe.waroquiers@skynet.be>
9600
9601	* inferiors.h: Include "gdb_vecs.h".
9602	(struct process_info): Add syscalls_to_catch.
9603	* inferiors.c (remove_process): Free syscalls_to_catch.
9604	* remote-utils.c (prepare_resume_reply): Report syscall_entry and
9605	syscall_return stops.
9606	* server.h (UNKNOWN_SYSCALL, ANY_SYSCALL): Define.
9607	* server.c (handle_general_set): Handle QCatchSyscalls.
9608	(handle_query): Report support for QCatchSyscalls.
9609	* target.h (struct target_ops): Add supports_catch_syscall.
9610	(target_supports_catch_syscall): New macro.
9611	* linux-low.h (struct linux_target_ops): Add get_syscall_trapinfo.
9612	(struct lwp_info): Add syscall_state.
9613	* linux-low.c (handle_extended_wait): Mark syscall_state as an entry.
9614	Maintain syscall_state and syscalls_to_catch across exec.
9615	(get_syscall_trapinfo): New function, proxy to the_low_target.
9616	(linux_low_ptrace_options): Enable PTRACE_O_TRACESYSGOOD.
9617	(linux_low_filter_event): Toggle syscall_state entry/return for
9618	syscall traps, and set it ignored for all others.
9619	(gdb_catching_syscalls_p): New function.
9620	(gdb_catch_this_syscall_p): New function.
9621	(linux_wait_1): Handle SYSCALL_SIGTRAP.
9622	(linux_resume_one_lwp_throw): Add PTRACE_SYSCALL possibility.
9623	(linux_supports_catch_syscall): New function.
9624	(linux_target_ops): Install it.
9625	* linux-x86-low.c (x86_get_syscall_trapinfo): New function.
9626	(the_low_target): Install it.
9627
96282016-01-12  Mike Frysinger  <vapier@gentoo.org>
9629
9630	* acinclude.m4: Include new ../warning.m4 file.
9631	* configure: Regenerated.
9632	* configure.ac: Replace all warning logic with AM_GDB_WARNINGS.
9633
96342016-01-12  Mike Frysinger  <vapier@gentoo.org>
9635
9636	* ax.c (is_goto_target): Mark static.
9637	* linux-low.c (register_addr): Likewise.
9638	(linux_fetch_registers, linux_store_registers): Likewise.
9639	* mem-break.c (any_persistent_commands): Fix old prototype.
9640	(add_commands_to_breakpoint): Mark static.
9641	* regcache.c (find_register_by_name): Delete unused func.
9642	* remote-utils.c (hex_or_minus_one): Mark static.
9643	* server.c (monitor_show_help): Mark static.
9644	(handle_query, handle_v_cont, handle_v_attach, handle_v_kill,
9645	handle_v_requests): Likewise.
9646
96472016-01-12  Pedro Alves  <palves@redhat.com>
9648
9649	Remove use of the registered trademark symbol throughout.
9650
96512016-01-08  Yao Qi  <yao.qi@linaro.org>
9652
9653	* remote-utils.c (getpkt): If c is '\003', call target hook
9654	request_interrupt.
9655
96562016-01-06  Yao Qi  <yao.qi@linaro.org>
9657
9658	* linux-aarch32-low.h (arm_abi_breakpoint): Move to
9659	linux-aarch32-low.c.
9660	(arm_eabi_breakpoint, arm_breakpoint): Likewise.
9661	(arm_breakpoint_len, thumb_breakpoint_len): Likewise.
9662	(thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
9663	(thumb2_breakpoint): Declare.
9664	* linux-aarch32-low.c (arm_abi_breakpoint): Moved from
9665	linux-aarch32-low.h.
9666	(arm_eabi_breakpoint, arm_breakpoint): Likewise.
9667	(arm_breakpoint_len, thumb_breakpoint_len): Likewise.
9668	(thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
9669
96702016-01-01  Joel Brobecker  <brobecker@adacore.com>
9671
9672	* gdbreplay.c (gdbreplay_version): Change copyright year in
9673	version message.
9674	* server.c (gdbserver_version): Likewise.
9675
96762015-12-28  Patrick Palka  <patrick@parcs.ath.cx>
9677
9678	* server.c (crc32_table): Delete.
9679	(crc32): Use libiberty's xcrc32 function.
9680
96812015-12-22  Joel Brobecker  <brobecker@adacore.com>
9682
9683	* lynx-low.c (lynx_delete_thread_callback): New function.
9684	(lynx_mourn): Properly delete our process and all of its
9685	threads.  Remove call to clear_inferiors.
9686
96872015-12-22  Joel Brobecker  <brobecker@adacore.com>
9688
9689	* target.c (thread_search_callback): Add check that
9690	the thread_stopped target callback is not NULL before
9691	calling it.
9692
96932015-12-21  Yao Qi  <yao.qi@linaro.org>
9694
9695	* linux-aarch32-low.h [__aarch64__]: Use arm_abi_breakpoint
9696	arm breakpoint.
9697
96982015-12-18  Antoine Tremblay  <antoine.tremblay@ericsson.com>
9699
9700	* server.c (handle_query): Call target_supports_software_single_step.
9701
97022015-12-18  Antoine Tremblay  <antoine.tremblay@ericsson.com>
9703
9704	* linux-low.c (single_step): New function.
9705	(linux_resume_one_lwp_throw): Call single_step.
9706	(start_step_over): Likewise.
9707
97082015-12-18  Antoine Tremblay  <antoine.tremblay@ericsson.com>
9709
9710	* Makefile.in (SFILES): Append arch/arm-linux.c,
9711	arch/arm-get-next-pcs.c.
9712	(arm-linux.o): New rule.
9713	(arm-get-next-pcs.o): New rule.
9714	* configure.srv (arm*-*-linux*): Add arm-get-next-pcs.o,
9715	arm-linux.o.
9716	* linux-aarch32-low.c (arm_abi_breakpoint): Remove macro.  Moved
9717	to linux-aarch32-low.c.
9718	(arm_eabi_breakpoint, arm_breakpoint): Likewise.
9719	(arm_breakpoint_len, thumb_breakpoint): Likewise.
9720	(thumb_breakpoint_len, thumb2_breakpoint): Likewise.
9721	(thumb2_breakpoint_len): Likewise.
9722	(arm_is_thumb_mode): Make non-static.
9723	* linux-aarch32-low.h (arm_abi_breakpoint): New macro.  Moved
9724	from linux-aarch32-low.c.
9725	(arm_eabi_breakpoint, arm_breakpoint): Likewise.
9726	(arm_breakpoint_len, thumb_breakpoint): Likewise.
9727	(thumb_breakpoint_len, thumb2_breakpoint): Likewise.
9728	(thumb2_breakpoint_len): Likewise.
9729	(arm_is_thumb_mode): New declaration.
9730	* linux-arm-low.c: Include arch/arm-linux.h
9731	aarch/arm-get-next-pcs.h, sys/syscall.h.
9732	(get_next_pcs_ops): New struct.
9733	(get_next_pcs_addr_bits_remove): New function.
9734	(get_next_pcs_is_thumb): New function.
9735	(get_next_pcs_read_memory_unsigned_integer): Likewise.
9736	(arm_sigreturn_next_pc): Likewise.
9737	(get_next_pcs_syscall_next_pc): Likewise.
9738	(arm_gdbserver_get_next_pcs): Likewise.
9739	(struct linux_target_ops) <arm_gdbserver_get_next_pcs>:
9740	Initialize.
9741	* linux-low.h: Move CORE_ADDR vector definition to gdb_vecs.h.
9742	* server.h: Include gdb_vecs.h.
9743
97442015-12-18  Antoine Tremblay  <antoine.tremblay@ericsson.com>
9745
9746	* Makefile.in (SFILES): Append common/common-regcache.c.
9747	(OBS): Append common-regcache.o.
9748	(common-regcache.o): New rule.
9749	* regcache.c (init_register_cache): Initialize cache to
9750	REG_UNAVAILABLE.
9751	(regcache_raw_read_unsigned): New function.
9752	* regcache.h (REG_UNAVAILABLE, REG_VALID): Replaced by shared
9753	register_status enum.
9754
97552015-12-18  Antoine Tremblay  <antoine.tremblay@ericsson.com>
9756
9757	* linux-aarch64-low.c (the_low_targets): Rename
9758	breakpoint_reinsert_addr to get_next_pcs.
9759	* linux-arm-low.c (the_low_targets): Likewise.
9760	* linux-bfin-low.c (the_low_targets): Likewise.
9761	* linux-cris-low.c (the_low_targets): Likewise.
9762	* linux-crisv32-low.c (the_low_targets): Likewise.
9763	* linux-low.c (can_software_single_step): Likewise.
9764	(install_software_single_step_breakpoints): New function.
9765	(start_step_over): Use install_software_single_step_breakpoints.
9766	* linux-low.h: New CORE_ADDR vector.
9767	(struct linux_target_ops) Rename breakpoint_reinsert_addr to
9768	get_next_pcs.
9769	* linux-mips-low.c (the_low_targets): Likewise.
9770	* linux-nios2-low.c (the_low_targets): Likewise.
9771	* linux-sparc-low.c (the_low_targets): Likewise.
9772
97732015-12-17  Pedro Alves  <palves@redhat.com>
9774
9775	* linux-low.c (linux_kill_one_lwp): Remove references to
9776	LinuxThreads.
9777	(kill_lwp): Remove HAVE_TKILL_SYSCALL check.  No longer fall back
9778	to 'kill'.
9779	(linux_init_signals): Delete.
9780	(initialize_low): Adjust.
9781	* thread-db.c (thread_db_init): Remove LinuxThreads reference.
9782
97832015-12-16  Pedro Alves  <palves@redhat.com>
9784
9785	* configure.ac (compiler warning flags): When testing a
9786	-Wno-foo option, check whether -Wfoo works instead.
9787	* configure: Regenerate.
9788
97892015-12-11  Don Breazeal  <donb@codesourcery.com>
9790
9791	* server.c (process_serial_event): Don't exit from gdbserver
9792	in remote mode if there are still active inferiors.
9793
97942015-12-11  Yao Qi  <yao.qi@linaro.org>
9795
9796	* linux-aarch64-low.c (aarch64_breakpoint_at): Call
9797	arm_breakpoint_at if the process is 32-bit.
9798
97992015-12-11  Yao Qi  <yao.qi@linaro.org>
9800
9801	* linux-aarch32-low.c [__aarch64__]: Use arm_abi_breakpoint
9802	arm breakpoint.
9803
98042015-12-07  Yao Qi  <yao.qi@linaro.org>
9805
9806	* configure.srv: Append arm.o to srv_tgtobj for
9807	aarch64*-*-linux* target.
9808	* linux-aarch32-low.c (arm_abi_breakpoint): New macro.  Moved
9809	from linux-arm-low.c.
9810	(arm_eabi_breakpoint, arm_breakpoint): Likewise.
9811	(arm_breakpoint_len, thumb_breakpoint): Likewise.
9812	(thumb_breakpoint_len, thumb2_breakpoint): Likewise.
9813	(thumb2_breakpoint_len): Likewise.
9814	(arm_is_thumb_mode, arm_breakpoint_at): Likewise.
9815	(arm_breakpoint_kinds): Likewise.
9816	(arm_breakpoint_kind_from_pc): Likewise.
9817	(arm_sw_breakpoint_from_kind): Likewise.
9818	(arm_breakpoint_kind_from_current_state): Likewise.
9819	* linux-aarch32-low.h (arm_breakpoint_kind_from_pc): Declare.
9820	(arm_sw_breakpoint_from_kind): Declare.
9821	(arm_breakpoint_kind_from_current_state): Declare.
9822	(arm_breakpoint_at): Declare.
9823	* linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): Call
9824	arm_sw_breakpoint_from_kind if process is 32-bit.
9825	(aarch64_breakpoint_kind_from_pc): New function.
9826	(aarch64_breakpoint_kind_from_current_state): New function.
9827	(the_low_target): Initialize fields breakpoint_kind_from_pc
9828	and breakpoint_kind_from_current_state.
9829	* linux-arm-low.c (arm_breakpoint_kinds): Move to
9830	linux-aarch32-low.c.
9831	(arm_abi_breakpoint, arm_eabi_breakpoint): Likewise.
9832	(arm_breakpoint, arm_breakpoint_len): Likewise.
9833	(thumb_breakpoint, thumb_breakpoint_len): Likewise.
9834	(thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
9835	(arm_is_thumb_mode): Likewise.
9836	(arm_breakpoint_at): Likewise.
9837	(arm_breakpoint_kind_from_pc): Likewise.
9838	(arm_sw_breakpoint_from_kind): Likewise.
9839	(arm_breakpoint_kind_from_current_state): Likewise.
9840
9841	Revert:
9842	2015-08-04  Yao Qi  <yao.qi@linaro.org>
9843
9844	* linux-aarch64-low.c (aarch64_supports_z_point_type): Return
9845	0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
9846	* server.c (extended_protocol): Remove "static".
9847	* server.h (extended_protocol): Declare it.
9848
98492015-12-04  Josh Stone  <jistone@redhat.com>
9850
9851	* target.h (struct target_ops) <arch_setup>: Rename to ...
9852	(struct target_ops) <post_create_inferior>: ... this.
9853	(target_arch_setup): Rename to ...
9854	(target_post_create_inferior): ... this, calling post_create_inferior.
9855	* server.c (start_inferior): Update target_arch_setup calls to
9856	target_post_create_inferior.
9857	* linux-low.c (linux_low_ptrace_options): Forward declare.
9858	(linux_arch_setup): Update its comment for general use.
9859	(linux_post_create_inferior): New, run arch_setup and setup ptrace.
9860	(struct linux_target_ops): Use linux_post_create_inferior.
9861	* lynx-low.c (struct lynx_target_ops): Update arch_setup stub comment
9862	to post_create_inferior.
9863	* nto-low.c (struct nto_target_ops): Likewise.
9864	* spu-low.c (struct spu_target_ops): Likewise.
9865	* win32-low.c (struct win32_target_ops): Likewise.
9866
98672015-12-03  Antoine Tremblay  <antoine.tremblay@ericsson.com>
9868
9869	* linux-arm-low.c: Remove duplicate arch/arm.h include.
9870
98712015-11-30  Antoine Tremblay  <antoine.tremblay@ericsson.com>
9872
9873	* linux-arm-low.c (arm_reinsert_addr): Remove function.
9874	(struct linux_target_ops <breakpoint_reinsert_addr>: Set to NULL.
9875	* linux-cris-low.c (cris_reinsert_addr> Remove function.
9876	(struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
9877	* linux-crisv32-low.c (cris_reinsert_addr): Remove function.
9878	(struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
9879	* linux-mips-low.c (mips_reinsert_addr): Remove function.
9880	(struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
9881	* linux-nios2-low.c (nios2_reinsert_addr): Remove function.
9882	(struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
9883	* linux-sparc-low.c (sparc_reinsert_addr): Remove function.
9884	(struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
9885
98862015-11-30  Antoine Tremblay  <antoine.tremblay@ericsson.com>
9887
9888	* linux-low.c (linux_look_up_symbols): Don't call
9889	linux_supports_traceclone.
9890	* linux-low.h (thread_db_init): Remove use_events argument.
9891	* thread-db.c (thread_db_use_event): Remove global variable.
9892	(struct thread_db) <td_thr_event_enable_p>: Remove field.
9893	(struct thread_db) <td_create_bp>: Remove field.
9894	(thread_db_create_event): Remove function.
9895	(thread_db_enable_reporting): Likewise.
9896	(find_one_thread): Don't check for thread_db_use_events.
9897	(attach_thread): Likewise.
9898	(thread_db_load_search): Remove td_thr_event_enable_p initialization.
9899	(try_thread_db_load_1): Don't check for thread_db_use_events.
9900	(thread_db_init): Remove use_events argument and thread events
9901	handling.
9902	(remove_thread_event_breakpoints): Remove function.
9903	(thread_db_detach): Remove call to remove_thred_event_breakpoints.
9904
99052015-11-30  Antoine Tremblay  <antoine.tremblay@ericsson.com>
9906
9907	* linux-aarch64-low.c (aarch64_supports_hardware_single_step):
9908	New function.
9909	(struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9910	* linux-arm-low.c (arm_supports_hardware_single_step): New function.
9911	(struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9912	* linux-bfin-low.c (bfin_supports_hardware_single_step): New function.
9913	(struct linux_target_ops) <bfin_supports_hardware_single_step>:
9914	Initialize.
9915	* linux-crisv32-low.c (cris_supports_hardware_single_step):
9916	New function.
9917	(struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9918	* linux-low.c (can_hardware_single_step): Use
9919	supports_hardware_single_step.
9920	(can_software_single_step): New function.
9921	(start_step_over): Call can_software_single_step.
9922	(linux_supports_hardware_single_step): New function.
9923	(struct target_ops) <supports_software_single_step>: Initialize.
9924	* linux-low.h (struct linux_target_ops)
9925	<supports_hardware_single_step>: Initialize.
9926	* linux-m32r-low.c (m32r_supports_hardware_single_step): New function.
9927	(struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9928	* linux-ppc-low.c (ppc_supports_hardware_single_step): New function.
9929	(struct linux_target_ops) <supports_hardware_single_step> Initialize.
9930	* linux-s390-low.c (s390_supports_hardware_single_step): New function.
9931	(struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9932	* linux-sh-low.c (sh_supports_hardware_single_step): New function.
9933	(struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9934	* linux-tic6x-low.c (tic6x_supports_hardware_single_step): New function.
9935	(struct linux_target_ops) <tic6x_supports_hardware_single_step>:
9936	Initialize.
9937	* linux-tile-low.c (tile_supports_hardware_single_step): New function.
9938	(struct linux_target_ops) <tile_supports_hardware_single_step>:
9939	Initialize.
9940	* linux-x86-low.c (x86_supports_hardware_single_step) New function.
9941	(struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9942	* linux-xtensa-low.c (xtensa_supports_hardware_single_step):
9943	New function.
9944	(struct linux_target_ops) <supports_hardware_single_step>: Initialize.
9945	* target.h (struct target_ops): <supports_software_single_step>:
9946	New field.
9947	(target_supports_software_single_step): New macro.
9948
99492015-11-30  Antoine Tremblay  <antoine.tremblay@ericsson.com>
9950
9951	* linux-low.c (linux_wait_1): Fix pc advance condition.
9952	* mem-break.c (reinsert_breakpoint_inserted_here): New function.
9953	* mem-break.h (reinsert_breakpoint_inserted_here): New declaration.
9954
99552015-11-30  Antoine Tremblay  <antoine.tremblay@ericsson.com>
9956
9957	* linux-arm-low.c (arm_is_thumb_mode): New function.
9958	(arm_breakpoint_at): Use arm_is_thumb_mode.
9959	(arm_breakpoint_kind_from_current_state): New function.
9960	(struct linux_target_ops) <breakpoint_kind_from_current_state>:
9961	Initialize.
9962	* linux-low.c (linux_wait_1): Call breakpoint_kind_from_current_state.
9963	(linux_breakpoint_kind_from_current_state): New function.
9964	(struct target_ops <breakpoint_kind_from_current_state>: Initialize.
9965	* linux-low.h (struct linux_target_ops)
9966	<breakpoint_kind_from_current_state>: New field.
9967	* target.h (struct target_ops): Likewise.
9968	(target_breakpoint_kind_from_current_state): New macro.
9969
99702015-11-30  Pedro Alves  <palves@redhat.com>
9971
9972	* linux-low.c (linux_resume): Wake up the event loop before
9973	returning.
9974
99752015-11-30  Pedro Alves  <palves@redhat.com>
9976
9977	* mem-break.c (check_gdb_bp_preconditions): Remove current_thread
9978	check.
9979	(set_gdb_breakpoint): If prepare_to_access_memory fails, set *ERR
9980	to -1.
9981	* target.c (struct thread_search): New structure.
9982	(thread_search_callback): New function.
9983	(prev_general_thread): New global.
9984	(prepare_to_access_memory, done_accessing_memory): New functions.
9985	* target.h (prepare_to_access_memory, done_accessing_memory):
9986	Replace macros with function declarations.
9987
99882015-11-30  Pedro Alves  <palves@redhat.com>
9989
9990	PR 14618
9991	* linux-low.c (linux_wait_1): If the last resumed thread is gone,
9992	report TARGET_WAITKIND_NO_RESUMED.
9993	* remote-utils.c (prepare_resume_reply): Handle
9994	TARGET_WAITKIND_NO_RESUMED.
9995	* server.c (report_no_resumed): New global.
9996	(handle_query) <qSupported>: Handle "no-resumed+".  Report
9997	"no-resumed+" support.
9998	(resume): When the target reports TARGET_WAITKIND_NO_RESUMED, only
9999	return error if the client doesn't support no-resumed events.
10000	(push_stop_notification): New function.
10001	(handle_target_event): Use it.  Report TARGET_WAITKIND_NO_RESUMED
10002	events if the client supports them.
10003
100042015-11-30  Pedro Alves  <palves@redhat.com>
10005
10006	* linux-low.c (thread_still_has_status_pending_p): Don't check
10007	vCont;t here.
10008	(lwp_resumed): New function.
10009	(status_pending_p_callback): Return early if the LWP is not
10010	supposed to be resumed.
10011
100122015-11-30  Pedro Alves  <palves@redhat.com>
10013
10014	* linux-low.c (handle_extended_wait): Assert that the LWP's
10015	waitstatus is TARGET_WAITKIND_IGNORE.  If GDB wants to hear about
10016	thread create events, leave the new child's status pending.
10017	(linux_low_filter_event): If GDB wants to hear about thread exit
10018	events, leave the LWP marked dead and don't delete it.
10019	(linux_wait_for_event_filtered): Don't check for thread exit.
10020	(filter_exit_event): New function.
10021	(linux_wait_1): Use it, when returning an exit event.
10022	(linux_resume_one_lwp_throw): Assert that the LWP's
10023	waitstatus is TARGET_WAITKIND_IGNORE.
10024	* remote-utils.c (prepare_resume_reply): Handle
10025	TARGET_WAITKIND_THREAD_CREATED and TARGET_WAITKIND_THREAD_EXITED.
10026	* server.c (report_thread_events): New global.
10027	(handle_general_set): Handle QThreadEvents.
10028	(handle_query) <qSupported>: Handle and report QThreadEvents+;
10029	(handle_target_event): Handle TARGET_WAITKIND_THREAD_CREATED and
10030	TARGET_WAITKIND_THREAD_EXITED.
10031	* server.h (report_thread_events): Declare.
10032
100332015-11-30  Pedro Alves  <palves@redhat.com>
10034
10035	* linux-low.c (resume_stopped_resumed_lwps): Don't check whether
10036	the thread's last_resume_kind was resume_stop.
10037
100382015-11-30  Pedro Alves  <palves@redhat.com>
10039
10040	* linux-low.c (linux_attach): In non-stop mode, wait for one stop
10041	before returning.
10042
100432015-11-30  Pedro Alves  <palves@redhat.com>
10044
10045	* server.c (handle_v_requests): Handle vCtrlC.
10046
100472015-11-30  Pedro Alves  <palves@redhat.com>
10048
10049	* gdbthread.h (find_any_thread_of_pid): Declare.
10050	* inferiors.c (thread_of_pid, find_any_thread_of_pid): New
10051	functions.
10052	* server.c (handle_query): If current_thread is NULL, look for
10053	another thread of the selected process.
10054
100552015-11-26  Daniel Colascione  <dancol@dancol.org>
10056	    Simon Marchi  <simon.marchi@ericsson.com>
10057
10058	* linux-low.c (linux_target_ops): Use linux_proc_tid_get_name.
10059	* server.c (handle_qxfer_threads_worker): Refactor to include thread
10060	name in reply.
10061	* target.h (struct target_ops) <thread_name>: New field.
10062	(target_thread_name): New macro.
10063
100642015-11-23  Joel Brobecker  <brobecker@adacore.com>
10065
10066	* regcache.h (regcache_invalidate_pid): Add declaration.
10067	* regcache.c (regcache_invalidate_pid): New function, extracted
10068	from regcache_invalidate.
10069	(regcache_invalidate): Reimplement using regcache_invalidate_pid.
10070	Add trivial documentation comment.
10071	* lynx-low.c: Use regcache_invalidate_pid instead of
10072	regcache_invalidate.
10073
100742015-11-23  Joel Brobecker  <brobecker@adacore.com>
10075
10076	* configure.ac: Do not call AC_CHECK_TYPES for Elf32_auxv_t
10077	and Elf64_auxv_t if the target is Android.
10078
100792015-11-22  Doug Evans  <xdje42@gmail.com>
10080
10081	* target.h: #include <sys/types.h>.
10082
100832015-11-19  Pedro Alves  <palves@redhat.com>
10084
10085	* linux-low.c (linux_process_qsupported): Change prototype.
10086	Adjust.
10087	* linux-low.h (struct linux_target_ops) <process_qsupported>:
10088	Change prototype.
10089	* linux-x86-low.c (x86_linux_process_qsupported): Change prototype
10090	and adjust to loop over all features.
10091	* server.c (handle_query) <qSupported>: Adjust to call
10092	target_process_qsupported once, passing it a vector of unprocessed
10093	features.
10094	* target.h (struct target_ops) <process_qsupported>: Change
10095	prototype.
10096	(target_process_qsupported): Adjust.
10097
100982015-11-19  Pedro Alves  <palves@redhat.com>
10099
10100	* configure.ac (ERROR_ON_WARNING): Don't check whether in C++
10101	mode.
10102	* configure: Regenerate.
10103
101042015-11-19  Pedro Alves  <palves@redhat.com>
10105
10106	* configure: Regenerate.
10107
101082015-11-19  Yao Qi  <yao.qi@linaro.org>
10109
10110	* linux-aarch64-low.c (emit_data_processing_reg): Change opcode
10111	type to uint32_t.
10112
101132015-11-19  Yao Qi  <yao.qi@linaro.org>
10114
10115	* linux-aarch64-low.c (enum aarch64_operand_type): New.
10116	(struct aarch64_operand): Move enum out.
10117
101182015-11-19  Yao Qi  <yao.qi@linaro.org>
10119
10120	* linux-aarch64-low.c (aarch64_fill_fpregset): Cast buf to
10121	struct user_fpsimd_state *.
10122	(aarch64_store_fpregset): Likewise.
10123
101242015-11-19  Yao Qi  <yao.qi@linaro.org>
10125
10126	* linux-aarch64-low.c (aarch64_fill_gregset): Cast buf to
10127	struct user_pt_regs *.
10128	(aarch64_store_gregset): Likewise.
10129
101302015-11-18  Pedro Alves  <palves@redhat.com>
10131
10132	* Makefile.in (all_object_files): Add $IPA_OBJS.
10133
101342015-11-17  Pedro Alves  <palves@redhat.com>
10135
10136	* win32-low.c (win32_resume): Use gdb_signal_from_host,
10137	GDB_SIGNAL_0 and gdb_signal_to_string.
10138
101392015-11-17  Pedro Alves  <palves@redhat.com>
10140
10141	* win32-low.c (handle_output_debug_string): Remove parameter.
10142	(win32_kill): Remove our_status local and adjust call to
10143	handle_output_debug_string.
10144	(get_child_debug_event): Adjust call to
10145	handle_output_debug_string.
10146
101472015-11-03  Simon Marchi  <simon.marchi@polymtl.ca>
10148
10149	* linux-mips-low.c (mips_fill_gregset): Add cast.
10150	(mips_store_gregset): Likewise.
10151	(mips_fill_fpregset): Likewise.
10152	(mips_store_fpregset): Likewise.
10153
101542015-11-03  Simon Marchi  <simon.marchi@polymtl.ca>
10155
10156	* linux-mips-low.c (mips_add_watchpoint): Rename private to
10157	priv.
10158
101592015-11-03  Simon Marchi  <simon.marchi@polymtl.ca>
10160
10161	* linux-mips-low.c (mips_linux_new_thread): Change type of
10162	watch_type to enum target_hw_bp_type.
10163
101642015-11-03  Simon Marchi  <simon.marchi@polymtl.ca>
10165
10166		* linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type):
10167		Change return type to arm_hwbp_type.
10168
101692015-11-03  Simon Marchi  <simon.marchi@polymtl.ca>
10170
10171	* linux-aarch32-low.c (arm_fill_gregset): Add cast.
10172	(arm_store_gregset): Likewise.
10173	* linux-arm-low.c (arm_get_hwcap): Likewise.
10174	(arm_read_description): Likewise.
10175
101762015-11-03  Simon Marchi  <simon.marchi@polymtl.ca>
10177
10178	* linux-aarch32-low.c (aarch32_regsets): Use NULL_REGSET.
10179
101802015-11-03  Simon Marchi  <simon.marchi@polymtl.ca>
10181
10182	* linux-ppc-low.c (ppc_get_hwcap): Add cast.
10183	(ppc_fill_vsxregset): Likewise.
10184	(ppc_store_vsxregset): Likewise.
10185	(ppc_fill_vrregset): Likewise.
10186	(ppc_store_vrregset): Likewise.
10187	(ppc_fill_evrregset): Likewise.
10188	(ppc_store_evrregset): Likewise.
10189
101902015-11-03  Simon Marchi  <simon.marchi@polymtl.ca>
10191
10192	* linux-ppc-low.c (ppc_usrregs_info): Remove
10193	forward-declaration.
10194	(ppc_arch_setup): Move lower in file.
10195
101962015-10-30  Simon Marchi  <simon.marchi@ericsson.com>
10197
10198	* proc-service.c (ps_pdread): Change CORE_ADDR cast to uintptr_t.
10199	(ps_pdwrite): Likewise.
10200
102012015-10-29 Henrik Wallin <henrik.wallin@windriver.com>
10202
10203	* linux-arm-low.c (arm_new_thread): Move pointer dereference
10204	to after assert checks.
10205
102062015-10-29  Simon Marchi  <simon.marchi@ericsson.com>
10207
10208	* proc-service.c (ps_pdread): Add/adjust casts.
10209	(ps_pdwrite): Add/adjust casts.
10210
102112015-10-29  Simon Marchi  <simon.marchi@polymtl.ca>
10212
10213	* server.c (handle_search_memory_1): Cast return value of
10214	memmem.
10215
102162015-10-29  Simon Marchi  <simon.marchi@polymtl.ca>
10217
10218	* server.c (write_qxfer_response): Change type of data to
10219	gdb_byte *.
10220
102212015-10-29  Pedro Alves  <palves@redhat.com>
10222
10223	* mem-break.c (Z_packet_to_bkpt_type): Add cast.
10224
102252015-10-29  Pedro Alves  <palves@redhat.com>
10226
10227	* tracepoint.c (clear_installed_tracepoints): Add casts.
10228
102292015-10-29  Pedro Alves  <palves@redhat.com>
10230
10231	* server.c (handle_v_cont, process_serial_event): Add enum
10232	gdb_signal casts to signal parsing code.
10233
102342015-10-29  Pedro Alves  <palves@redhat.com>
10235
10236	* linux-low.h (NULL_REGSET): Define.
10237	* linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
10238	* linux-arm-low.c (arm_regsets): Likewise.
10239	* linux-crisv32-low.c (cris_regsets): Likewise.
10240	* linux-m68k-low.c (m68k_regsets): Likewise.
10241	* linux-mips-low.c (mips_regsets): Likewise.
10242	* linux-nios2-low.c (nios2_regsets): Likewise.
10243	* linux-ppc-low.c (ppc_regsets): Likewise.
10244	* linux-s390-low.c (s390_regsets): Likewise.
10245	* linux-sh-low.c (sh_regsets): Likewise.
10246	* linux-sparc-low.c (sparc_regsets): Likewise.
10247	* linux-tic6x-low.c (tic6x_regsets): Likewise.
10248	* linux-tile-low.c (tile_regsets): Likewise.
10249	* linux-x86-low.c (x86_regsets): Likewise.
10250	* linux-xtensa-low.c (xtensa_regsets): Likewise.
10251
102522015-10-29  Pedro Alves  <palves@redhat.com>
10253
10254	* linux-low.h (NULL_REGSET): Define.
10255	* linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
10256	* linux-arm-low.c (arm_regsets): Likewise.
10257	* linux-crisv32-low.c (cris_regsets): Likewise.
10258	* linux-m68k-low.c (m68k_regsets): Likewise.
10259	* linux-mips-low.c (mips_regsets): Likewise.
10260	* linux-nios2-low.c (nios2_regsets): Likewise.
10261	* linux-ppc-low.c (ppc_regsets): Likewise.
10262	* linux-s390-low.c (s390_regsets): Likewise.
10263	* linux-sh-low.c (sh_regsets): Likewise.
10264	* linux-sparc-low.c (sparc_regsets): Likewise.
10265	* linux-tic6x-low.c (tic6x_regsets): Likewise.
10266	* linux-tile-low.c (tile_regsets): Likewise.
10267	* linux-x86-low.c (x86_regsets): Likewise.
10268	* linux-xtensa-low.c (xtensa_regsets): Likewise.
10269
102702015-10-26  Doug Evans  <dje@google.com>
10271
10272	* linux-low.c (__SIGRTMIN): Move to nat/linux-nat.h.
10273
102742015-10-26  Doug Evans  <dje@google.com>
10275
10276	* linux-low.c (W_STOPCODE): Moved to common/gdb_wait.h.
10277
102782015-10-26  Doug Evans  <dje@google.com>
10279
10280	* thread-db.c (find_one_thread): Cast ti.ti_tid to unsigned long
10281	for debug_printf.
10282	(attach_thread, find_new_threads_callback): Ditto.
10283
102842015-10-23  Antoine Tremblay  <antoine.tremblay@ericsson.com>
10285
10286	* mem-break.h (set_breakpoint_data): Remove.
10287
102882015-10-23  Antoine Tremblay  <antoine.tremblay@ericsson.com>
10289
10290	* nto-low.c (nto_sw_breakpoint_from_kind): New function.
10291	(struct target_ops) <sw_breakpoint_from_kind>: Initialize.
10292	(initialize_low): Remove set_breakpoint_data call.
10293	* spu-low.c (spu_sw_breakpoint_from_kind): New function.
10294	(struct target_ops) <sw_breakpoint_from_kind>: Iniitalize.
10295	(initialize_low): Remove set_breakpoint_data call.
10296	* win32-low.c (win32_sw_breakpoint_from_kind): New function.
10297	(struct target_ops) <sw_breakpoint_from_kind>: Initialize.
10298	(initialize_low): Remove set_breakpoint_data call.
10299
103002015-10-23  Antoine Tremblay  <antoine.tremblay@ericsson.com>
10301
10302	* linux-low.c (default_breakpoint_kind_from_pc): Move to target.c.
10303	* mem-break.c (set_breakpoint_at): Use target_breakpoint_kind_from_pc.
10304	* target.c (default_breakpoint_kind_from_pc): Moved from linux-low.c
10305	* target.h (target_breakpoint_kind_from_pc): New macro.
10306
103072015-10-22  Antoine Tremblay  <antoine.tremblay@ericsson.com>
10308
10309	* linux-low.c (default_breakpoint_kind_from_pc): New function.
10310	(linux_breakpoint_kind_from_pc): Use default_breakpoint_kind_from_pc for
10311	the default breakpoint kind.
10312
103132015-10-21  Antoine Tremblay  <antoine.tremblay@ericsson.com>
10314
10315	* linux-arm-low.c (arm_supports_z_point_type): Add software
10316	breakpoint support.
10317
103182015-10-21  Antoine Tremblay  <antoine.tremblay@ericsson.com>
10319
10320	* linux-arm-low.c: Refactor breakpoint definitions.
10321	(arm_breakpoint_at): Adjust for arm_abi_breakpoint.
10322	(arm_sw_breakpoint_from_kind): Adjust for arm_breakpoint.
10323
103242015-10-21  Antoine Tremblay  <antoine.tremblay@ericsson.com>
10325
10326	* Makefile.in: Add arm.c/o.
10327	* configure.srv: Likewise.
10328	* linux-arm-low.c (arm_breakpoint_kinds): New enum.
10329	(arm_breakpoint_kind_from_pc): New function.
10330	(arm_sw_breakpoint_from_kind): Return proper kind.
10331	(struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize.
10332
103332015-10-21  Antoine Tremblay  <antoine.tremblay@ericsson.com>
10334
10335	* linux-low.c (initialize_low): Ajdust for breakpoint global variables
10336	removal.
10337	* mem-break.c : Remove breakpoint_data/breakpoint_len global variables.
10338	(struct raw_breakpoint) <size>: Remove.
10339	(struct raw_breakpoint) <kind>: Add.
10340	(bp_size): New function.
10341	(bp_opcode): Likewise.
10342	(find_raw_breakpoint_at): Adjust for kind.
10343	(insert_memory_breakpoint): Adjust for kind call bp_size,bp_opcode.
10344	(remove_memory_breakpoint): Adjust for kind call bp_size.
10345	(set_raw_breakpoint_at): Adjust for kind.
10346	(set_breakpoint): Likewise.
10347	(set_breakpoint_at): Call breakpoint_kind_from_pc.
10348	(delete_raw_breakpoint): Adjust for kind.
10349	(delete_breakpoint): Likewise.
10350	(find_gdb_breakpoint): Likewise.
10351	(set_gdb_breakpoint_1): Likewise.
10352	(set_gdb_breakpoint): Likewise.
10353	(delete_gdb_breakpoint_1): Likewise.
10354	(delete_gdb_breakpoint): Likewise.
10355	(uninsert_raw_breakpoint): Likewise.
10356	(reinsert_raw_breakpoint): Likewise.
10357	(set_breakpoint_data): Remove.
10358	(validate_inserted_breakpoint): Adjust for kind call bp_size,bp_opcode.
10359	(check_mem_read): Adjust for kind call bp_size.
10360	(check_mem_write): Adjust for kind call bp_size,bp_opcode.
10361	(clone_one_breakpoint): Adjust for kind.
10362	* mem-break.h (set_gdb_breakpoint): Likewise.
10363	(delete_gdb_breakpoint): Likewise.
10364	* server.c (process_serial_event): Likewise.
10365
103662015-10-21  Antoine Tremblay  <antoine.tremblay@ericsson.com>
10367
10368	* linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): New function.
10369	(struct linux_target_ops) <breakpoint>: Remove.
10370	(struct linux_target_ops) <breakpoint_len>: Remove.
10371	(struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
10372	(struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
10373	* linux-arm-low.c (arm_breakpoint_kind_from_pc): New function.
10374	(arm_sw_breakpoint_from_kind): New function.
10375	* linux-bfin-low.c (bfin_sw_breakpoint_from_kind): New function.
10376	(struct linux_target_ops) <breakpoint>: Remove.
10377	(struct linux_target_ops) <breakpoint_len>: Remove.
10378	(struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
10379	(struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
10380	* linux-cris-low.c (cris_sw_breakpoint_from_kind): New function.
10381	(struct linux_target_ops) <breakpoint>: Remove.
10382	(struct linux_target_ops) <breakpoint_len>: Remove.
10383	(struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
10384	(struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
10385	* linux-crisv32-low.c (cris_sw_breakpoint_from_kind): New function.
10386	(struct linux_target_ops) <breakpoint>: Remove.
10387	(struct linux_target_ops) <breakpoint_len>: Remove.
10388	(struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
10389	(struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
10390	* linux-low.c (linux_wait_1): Call breakpoint_kind_from_pc
10391	and sw_breakpoint_from_kind to increment the pc.
10392	(linux_breakpoint_kind_from_pc): New function.
10393	(linux_sw_breakpoint_from_kind): New function.
10394	(struct target_ops) <sw_breakpoint_from_kind>: Initialize field.
10395	(initialize_low): Call breakpoint_kind_from_pc and
10396	sw_breakpoint_from_kind to replace breakpoint_data/len.
10397	* linux-low.h (struct linux_target_ops) <breakpoint_kind_from_pc>:
10398	New field.
10399	(struct linux_target_ops) <sw_breakpoint_from_kind>: Likewise.
10400	* linux-m32r-low.c (m32r_sw_breakpoint_from_kind): New function.
10401	(struct linux_target_ops) <breakpoint>: Remove.
10402	(struct linux_target_ops) <breakpoint_len>: Remove.
10403	(struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
10404	(struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
10405	* linux-m68k-low.c (m68k_sw_breakpoint_from_kind): New function.
10406	(struct linux_target_ops) <breakpoint>: Remove.
10407	(struct linux_target_ops) <breakpoint_len>: Remove.
10408	(struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
10409	(struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
10410	* linux-mips-low.c (mips_sw_breakpoint_from_kind): New function.
10411	(struct linux_target_ops) <breakpoint>: Remove.
10412	(struct linux_target_ops) <breakpoint_len>: Remove.
10413	(struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
10414	(struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
10415	* linux-nios2-low.c (nios2_sw_breakpoint_from_kind): New function.
10416	(struct linux_target_ops) <breakpoint>: Remove.
10417	(struct linux_target_ops) <breakpoint_len>: Remove.
10418	(struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
10419	(struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
10420	* linux-ppc-low.c (ppc_sw_breakpoint_from_kind): New function.
10421	(struct linux_target_ops) <breakpoint>: Remove.
10422	(struct linux_target_ops) <breakpoint_len>: Remove.
10423	(struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
10424	(struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
10425	* linux-s390-low.c (s390_sw_breakpoint_from_kind): New function.
10426	(struct linux_target_ops) <breakpoint>: Remove.
10427	(struct linux_target_ops) <breakpoint_len>: Remove.
10428	(struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
10429	(struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
10430	* linux-sh-low.c (sh_sw_breakpoint_from_kind): New function.
10431	(struct linux_target_ops) <breakpoint>: Remove.
10432	(struct linux_target_ops) <breakpoint_len>: Remove.
10433	(struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
10434	(struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
10435	* linux-sparc-low.c (sparc_sw_breakpoint_from_kind): New function.
10436	(struct linux_target_ops) <breakpoint>: Remove.
10437	(struct linux_target_ops) <breakpoint_len>: Remove.
10438	(struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
10439	(struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
10440	* linux-tic6x-low.c (tic6x_sw_breakpoint_from_kind): New function.
10441	(struct linux_target_ops) <breakpoint>: Remove.
10442	(struct linux_target_ops) <breakpoint_len>: Remove.
10443	(struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
10444	(struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
10445	* linux-tile-low.c (tile_sw_breakpoint_from_kind): New function.
10446	* linux-x86-low.c (x86_sw_breakpoint_from_kind): New function.
10447	(struct linux_target_ops) <breakpoint>: Remove.
10448	(struct linux_target_ops) <breakpoint_len>: Remove.
10449	(struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
10450	(struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
10451	* linux-xtensa-low.c (xtensa_sw_breakpoint_from_kind) New function.
10452	(struct linux_target_ops) <breakpoint>: Remove.
10453	(struct linux_target_ops) <breakpoint_len>: Remove.
10454	(struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
10455	(struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
10456
104572015-10-21  Antoine Tremblay  <antoine.tremblay@ericsson.com>
10458
10459	* linux-cris-low.c (cris_get_pc): Remove void arg.
10460
104612015-10-16  Aleksandar Ristovski  <aristovski@qnx.com>
10462
10463	* gdbserver/nto-low.c (nto_insert_point, nto_remove_point): Fix
10464	variable name.
10465
104662015-10-16  Aleksandar Ristovski  <aristovski@qnx.com>
10467
10468	* inferiors.c (thread_pid_matches_callback): New function.
10469	(find_thread_process): New function.
10470	(remove_thread): Reset current_thread.
10471	(remove_process): Assert threads have been removed first.
10472
104732015-10-15  Yao Qi  <yao.qi@linaro.org>
10474
10475	* linux-aarch64-low.c (aarch64_insert_point): Set len to 2
10476	if it is 3.
10477	(aarch64_remove_point): Likewise.
10478	* regcache.c (regcache_register_size): New function.
10479
104802015-10-12  Yao Qi  <yao.qi@linaro.org>
10481
10482	* linux-aarch64-low.c: Update all callers as emit_load_store
10483	is renamed to aarch64_emit_load_store.
10484
104852015-10-12  Yao Qi  <yao.qi@linaro.org>
10486
10487	* linux-aarch64-low.c: Update all callers of function renaming
10488	from emit_insn to aarch64_emit_insn.
10489
104902015-10-12  Yao Qi  <yao.qi@linaro.org>
10491
10492	* linux-aarch64-low.c (enum aarch64_opcodes): Move to
10493	arch/aarch64-insn.h.
10494	(struct aarch64_memory_operand): Likewise.
10495	(ENCODE): Likewise.
10496	(emit_insn): Move to arch/aarch64-insn.c.
10497	(emit_b, emit_bcond, emit_cb, emit_tb): Remove.
10498	(emit_load_store): Move to arch/aarch64-insn.c.
10499	(emit_ldr, emit_ldrb, emit_ldrsw, emit_nop): Remove.
10500	(can_encode_int32): Remove.
10501
105022015-10-12  Yao Qi  <yao.qi@linaro.org>
10503
10504	* linux-aarch64-low.c (extract_signed_bitfield): Remove.
10505	(aarch64_decode_ldr_literal): Move to gdb/arch/aarch64-insn.c.
10506	(aarch64_relocate_instruction): Likewise.
10507	(struct aarch64_insn_data): Move to gdb/arch/aarch64-insn.h.
10508	(struct aarch64_insn_visitor): Likewise.
10509
105102015-10-12  Yao Qi  <yao.qi@linaro.org>
10511
10512	* linux-aarch64-low.c (struct aarch64_insn_data): New.
10513	(struct aarch64_insn_visitor): New.
10514	(struct aarch64_insn_relocation_data): New.
10515	(aarch64_ftrace_insn_reloc_b): New function.
10516	(aarch64_ftrace_insn_reloc_b_cond): Likewise.
10517	(aarch64_ftrace_insn_reloc_cb): Likewise.
10518	(aarch64_ftrace_insn_reloc_tb): Likewise.
10519	(aarch64_ftrace_insn_reloc_adr): Likewise.
10520	(aarch64_ftrace_insn_reloc_ldr_literal): Likewise.
10521	(aarch64_ftrace_insn_reloc_others): Likewise.
10522	(visitor): New.
10523	(aarch64_relocate_instruction): Use visitor.
10524
105252015-10-12  Yao Qi  <yao.qi@linaro.org>
10526
10527	* linux-aarch64-low.c (aarch64_relocate_instruction): Return
10528	int.  Add argument buf.
10529	(aarch64_install_fast_tracepoint_jump_pad): Pass buf to
10530	aarch64_relocate_instruction.
10531
105322015-10-12  Yao Qi  <yao.qi@linaro.org>
10533
10534	* linux-aarch64-low.c (aarch64_relocate_instruction): Add
10535	argument insn.  Remove local variable insn.  Don't call
10536	target_read_uint32.
10537	(aarch64_install_fast_tracepoint_jump_pad): Call
10538	target_read_uint32.
10539
105402015-09-30  Yao Qi  <yao.qi@linaro.org>
10541
10542	* linux-aarch64-low.c (emit_movk): Shorten a long line.
10543	(emit_load_store_pair): Likewise.
10544
105452015-09-25  Simon Marchi  <simon.marchi@ericsson.com>
10546
10547	* dll.c (match_dll): Add cast(s).
10548	(unloaded_dll): Likewise.
10549	* linux-low.c (second_thread_of_pid_p): Likewise.
10550	(delete_lwp_callback): Likewise.
10551	(count_events_callback): Likewise.
10552	(select_event_lwp_callback): Likewise.
10553	(linux_set_resume_request): Likewise.
10554	* server.c (accumulate_file_name_length): Likewise.
10555	(emit_dll_description): Likewise.
10556	(handle_qxfer_threads_worker): Likewise.
10557	(visit_actioned_threads): Likewise.
10558	* thread-db.c (any_thread_of): Likewise.
10559	* tracepoint.c (same_process_p): Likewise.
10560	(match_blocktype): Likewise.
10561	(build_traceframe_info_xml): Likewise.
10562
105632015-09-25  Simon Marchi  <simon.marchi@ericsson.com>
10564
10565	* ax.c (gdb_parse_agent_expr): Add cast to allocation result
10566	assignment.
10567	(gdb_unparse_agent_expr): Likewise.
10568	* hostio.c (require_data): Likewise.
10569	(handle_pread): Likewise.
10570	* linux-low.c (disable_regset): Likewise.
10571	(fetch_register): Likewise.
10572	(store_register): Likewise.
10573	(get_dynamic): Likewise.
10574	(linux_qxfer_libraries_svr4): Likewise.
10575	* mem-break.c (delete_fast_tracepoint_jump): Likewise.
10576	(set_fast_tracepoint_jump): Likewise.
10577	(uninsert_fast_tracepoint_jumps_at): Likewise.
10578	(reinsert_fast_tracepoint_jumps_at): Likewise.
10579	(validate_inserted_breakpoint): Likewise.
10580	(clone_agent_expr): Likewise.
10581	* regcache.c (init_register_cache): Likewise.
10582	* remote-utils.c (putpkt_binary_1): Likewise.
10583	(decode_M_packet): Likewise.
10584	(decode_X_packet): Likewise.
10585	(look_up_one_symbol): Likewise.
10586	(relocate_instruction): Likewise.
10587	(monitor_output): Likewise.
10588	* server.c (handle_search_memory): Likewise.
10589	(handle_qxfer_exec_file): Likewise.
10590	(handle_qxfer_libraries): Likewise.
10591	(handle_qxfer): Likewise.
10592	(handle_query): Likewise.
10593	(handle_v_cont): Likewise.
10594	(handle_v_run): Likewise.
10595	(captured_main): Likewise.
10596	* target.c (write_inferior_memory): Likewise.
10597	* thread-db.c (try_thread_db_load_from_dir): Likewise.
10598	* tracepoint.c (init_trace_buffer): Likewise.
10599	(add_tracepoint_action): Likewise.
10600	(add_traceframe): Likewise.
10601	(add_traceframe_block): Likewise.
10602	(cmd_qtdpsrc): Likewise.
10603	(cmd_qtdv): Likewise.
10604	(cmd_qtstatus): Likewise.
10605	(response_source): Likewise.
10606	(response_tsv): Likewise.
10607	(cmd_qtnotes): Likewise.
10608	(gdb_collect): Likewise.
10609	(initialize_tracepoint): Likewise.
10610
106112015-09-21  Pierre Langlois  <pierre.langlois@arm.com>
10612
10613	* linux-aarch64-low-.c: Include ax.h and tracepoint.h.
10614	(enum aarch64_opcodes) <RET>, <SUBS>, <AND>, <ORR>, <ORN>,
10615	<EOR>, <LSLV>, <LSRV>, <ASRV>, <SBFM>, <UBFM>, <CSINC>, <MUL>,
10616	<NOP>: New.
10617	(enum aarch64_condition_codes): New enum.
10618	(w0): New static global.
10619	(fp): Likewise.
10620	(lr): Likewise.
10621	(struct aarch64_memory_operand) <type>: New
10622	MEMORY_OPERAND_POSTINDEX type.
10623	(postindex_memory_operand): New helper function.
10624	(emit_ret): New function.
10625	(emit_load_store_pair): New function, factored out of emit_stp
10626	with support for MEMORY_OPERAND_POSTINDEX.
10627	(emit_stp): Rewrite using emit_load_store_pair.
10628	(emit_ldp): New function.
10629	(emit_load_store): Likewise.
10630	(emit_ldr): Mention post-index instruction in comment.
10631	(emit_ldrh): New function.
10632	(emit_ldrb): New function.
10633	(emit_ldrsw): Mention post-index instruction in comment.
10634	(emit_str): Likewise.
10635	(emit_subs): New function.
10636	(emit_cmp): Likewise.
10637	(emit_and): Likewise.
10638	(emit_orr): Likewise.
10639	(emit_orn): Likewise.
10640	(emit_eor): Likewise.
10641	(emit_mvn): Likewise.
10642	(emit_lslv): Likewise.
10643	(emit_lsrv): Likewise.
10644	(emit_asrv): Likewise.
10645	(emit_mul): Likewise.
10646	(emit_sbfm): Likewise.
10647	(emit_sbfx): Likewise.
10648	(emit_ubfm): Likewise.
10649	(emit_ubfx): Likewise.
10650	(emit_csinc): Likewise.
10651	(emit_cset): Likewise.
10652	(emit_nop): Likewise.
10653	(emit_ops_insns): New helper function.
10654	(emit_pop): Likewise.
10655	(emit_push): Likewise.
10656	(aarch64_emit_prologue): New function.
10657	(aarch64_emit_epilogue): Likewise.
10658	(aarch64_emit_add): Likewise.
10659	(aarch64_emit_sub): Likewise.
10660	(aarch64_emit_mul): Likewise.
10661	(aarch64_emit_lsh): Likewise.
10662	(aarch64_emit_rsh_signed): Likewise.
10663	(aarch64_emit_rsh_unsigned): Likewise.
10664	(aarch64_emit_ext): Likewise.
10665	(aarch64_emit_log_not): Likewise.
10666	(aarch64_emit_bit_and): Likewise.
10667	(aarch64_emit_bit_or): Likewise.
10668	(aarch64_emit_bit_xor): Likewise.
10669	(aarch64_emit_bit_not): Likewise.
10670	(aarch64_emit_equal): Likewise.
10671	(aarch64_emit_less_signed): Likewise.
10672	(aarch64_emit_less_unsigned): Likewise.
10673	(aarch64_emit_ref): Likewise.
10674	(aarch64_emit_if_goto): Likewise.
10675	(aarch64_emit_goto): Likewise.
10676	(aarch64_write_goto_address): Likewise.
10677	(aarch64_emit_const): Likewise.
10678	(aarch64_emit_call): Likewise.
10679	(aarch64_emit_reg): Likewise.
10680	(aarch64_emit_pop): Likewise.
10681	(aarch64_emit_stack_flush): Likewise.
10682	(aarch64_emit_zero_ext): Likewise.
10683	(aarch64_emit_swap): Likewise.
10684	(aarch64_emit_stack_adjust): Likewise.
10685	(aarch64_emit_int_call_1): Likewise.
10686	(aarch64_emit_void_call_2): Likewise.
10687	(aarch64_emit_eq_goto): Likewise.
10688	(aarch64_emit_ne_goto): Likewise.
10689	(aarch64_emit_lt_goto): Likewise.
10690	(aarch64_emit_le_goto): Likewise.
10691	(aarch64_emit_gt_goto): Likewise.
10692	(aarch64_emit_ge_got): Likewise.
10693	(aarch64_emit_ops_impl): New static global variable.
10694	(aarch64_emit_ops): New target function, return
10695	&aarch64_emit_ops_impl.
10696	(struct linux_target_ops): Install it.
10697
106982015-09-21  Pierre Langlois  <pierre.langlois@arm.com>
10699
10700	* Makefile.in (linux-aarch64-ipa.o, aarch64-ipa.o): New rules.
10701	* configure.srv (aarch64*-*-linux*): Add linux-aarch64-ipa.o and
10702	aarch64-ipa.o.
10703	* linux-aarch64-ipa.c: New file.
10704	* linux-aarch64-low.c: Include arch/aarch64-insn.h, inttypes.h
10705	and endian.h.
10706	(aarch64_get_thread_area): New target method.
10707	(extract_signed_bitfield): New helper function.
10708	(aarch64_decode_ldr_literal): New function.
10709	(enum aarch64_opcodes): New enum.
10710	(struct aarch64_register): New struct.
10711	(struct aarch64_operand): New struct.
10712	(x0): New static global.
10713	(x1): Likewise.
10714	(x2): Likewise.
10715	(x3): Likewise.
10716	(x4): Likewise.
10717	(w2): Likewise.
10718	(ip0): Likewise.
10719	(sp): Likewise.
10720	(xzr): Likewise.
10721	(aarch64_register): New helper function.
10722	(register_operand): Likewise.
10723	(immediate_operand): Likewise.
10724	(struct aarch64_memory_operand): New struct.
10725	(offset_memory_operand): New helper function.
10726	(preindex_memory_operand): Likewise.
10727	(enum aarch64_system_control_registers): New enum.
10728	(ENCODE): New macro.
10729	(emit_insn): New helper function.
10730	(emit_b): New function.
10731	(emit_bcond): Likewise.
10732	(emit_cb): Likewise.
10733	(emit_tb): Likewise.
10734	(emit_blr): Likewise.
10735	(emit_stp): Likewise.
10736	(emit_ldp_q_offset): Likewise.
10737	(emit_stp_q_offset): Likewise.
10738	(emit_load_store): Likewise.
10739	(emit_ldr): Likewise.
10740	(emit_ldrsw): Likewise.
10741	(emit_str): Likewise.
10742	(emit_ldaxr): Likewise.
10743	(emit_stxr): Likewise.
10744	(emit_stlr): Likewise.
10745	(emit_data_processing_reg): Likewise.
10746	(emit_data_processing): Likewise.
10747	(emit_add): Likewise.
10748	(emit_sub): Likewise.
10749	(emit_mov): Likewise.
10750	(emit_movk): Likewise.
10751	(emit_mov_addr): Likewise.
10752	(emit_mrs): Likewise.
10753	(emit_msr): Likewise.
10754	(emit_sevl): Likewise.
10755	(emit_wfe): Likewise.
10756	(append_insns): Likewise.
10757	(can_encode_int32_in): New helper function.
10758	(aarch64_relocate_instruction): New function.
10759	(aarch64_install_fast_tracepoint_jump_pad): Likewise.
10760	(aarch64_get_min_fast_tracepoint_insn_len): Likewise.
10761	(struct linux_target_ops): Install aarch64_get_thread_area,
10762	aarch64_install_fast_tracepoint_jump_pad and
10763	aarch64_get_min_fast_tracepoint_insn_len.
10764
107652015-09-21  Pierre Langlois  <pierre.langlois@arm.com>
10766
10767	* Makefile.in (aarch64-insn.o): New rule.
10768	* configure.srv (aarch64*-*-linux*): Add aarch64-insn.o.
10769
107702015-09-21  Yao Qi  <yao.qi@linaro.org>
10771
10772	* ax.c [!IN_PROCESS_AGENT] (gdb_agent_op_sizes): Define it.
10773
107742015-09-21  Yao Qi  <yao.qi@linaro.org>
10775
10776	* tracepoint.c (max_jump_pad_size): Remove.
10777
107782015-09-18  Yao Qi  <yao.qi@linaro.org>
10779
10780	* linux-aarch64-low.c: Don't include sys/uio.h.
10781	(ps_get_thread_area): Call aarch64_ps_get_thread_area.
10782
107832015-09-16  Wei-cheng Wang  <cole945@gmail.com>
10784
10785	* tracepoint.c (eval_result_type): Change prototype.
10786	(condition_true_at_tracepoint): Fix argument to compiled_cond.
10787
107882015-09-15  Pedro Alves  <palves@redhat.com>
10789
10790	* remote-utils.c (prepare_resume_reply) <TARGET_WAITKIND_EXECD>:
10791	Check whether to report exec events instead of checking whether
10792	multiprocess is enabled.
10793
107942015-09-15  Pedro Alves  <palves@redhat.com>
10795
10796	PR remote/18965
10797	* remote-utils.c (prepare_resume_reply): Merge
10798	TARGET_WAITKIND_VFORK_DONE switch case with the
10799	TARGET_WAITKIND_FORKED case.
10800
108012015-09-15  Yao Qi  <yao.qi@linaro.org>
10802
10803	* server.c (handle_query): Check string comparison using
10804	"else if" instead of "if".
10805
108062015-09-15  Yao Qi  <yao.qi@linaro.org>
10807
10808	* server.c (vCont_supported): New global variable.
10809	(handle_query): Set vCont_supported to 1 if "vContSupported+"
10810	matches.  Append ";vContSupported+" to own_buf.
10811	(handle_v_requests): Append ";s;S" to own_buf if target supports
10812	hardware single step or vCont_supported is false.
10813	(capture_main): Set vCont_supported to zero.
10814
108152015-09-15  Yao Qi  <yao.qi@linaro.org>
10816
10817	* linux-low.c (linux_supports_conditional_breakpoints): Rename
10818	it to ...
10819	(linux_supports_hardware_single_step): ... New function.
10820	(linux_target_ops): Update.
10821	* lynx-low.c (lynx_target_ops): Set field
10822	supports_hardware_single_step to target_can_do_hardware_single_step.
10823	* nto-low.c (nto_target_ops): Likewise.
10824	* spu-low.c (spu_target_ops): Likewise.
10825	* win32-low.c (win32_target_ops): Likewise.
10826	* target.c (target_can_do_hardware_single_step): New function.
10827	* target.h (struct target_ops) <supports_conditional_breakpoints>:
10828	Remove.  <supports_hardware_single_step>: New field.
10829	(target_supports_conditional_breakpoints): Remove.
10830	(target_supports_hardware_single_step): New macro.
10831	(target_can_do_hardware_single_step): Declare.
10832	* server.c (handle_query): Use target_supports_hardware_single_step
10833	instead of target_supports_conditional_breakpoints.
10834
108352015-09-15  Yao Qi  <yao.qi@linaro.org>
10836
10837	* linux-aarch64-low.c (aarch64_linux_siginfo_fixup): New
10838	function.
10839	(struct linux_target_ops the_low_target): Install
10840	aarch64_linux_siginfo_fixup.
10841
108422015-09-11  Don Breazeal  <donb@codesourcery.com>
10843	    Luis Machado  <lgustavo@codesourcery.com>
10844
10845	* linux-low.c (linux_mourn): Static declaration.
10846	(linux_arch_setup): Move in front of
10847	handle_extended_wait.
10848	(linux_arch_setup_thread): New function.
10849	(handle_extended_wait): Handle exec events.  Call
10850	linux_arch_setup_thread.  Make event_lwp argument a
10851	pointer-to-a-pointer.
10852	(check_zombie_leaders): Do not check stopped threads.
10853	(linux_low_ptrace_options): Add PTRACE_O_TRACEEXEC.
10854	(linux_low_filter_event): Add lwp and thread for exec'ing
10855	non-leader thread if leader thread has been deleted.
10856	Refactor code into linux_arch_setup_thread and call it.
10857	Pass child lwp pointer by reference to handle_extended_wait.
10858	(linux_wait_for_event_filtered): Update comment.
10859	(linux_wait_1): Prevent clobbering exec event status.
10860	(linux_supports_exec_events): New function.
10861	(linux_target_ops) <supports_exec_events>: Initialize new member.
10862	* lynx-low.c (lynx_target_ops) <supports_exec_events>: Initialize
10863	new member.
10864	* remote-utils.c (prepare_resume_reply): New stop reason 'exec'.
10865	* server.c (report_exec_events): New global variable.
10866	(handle_query): Handle qSupported query for exec-events feature.
10867	(captured_main): Initialize report_exec_events.
10868	* server.h (report_exec_events): Declare new global variable.
10869	* target.h (struct target_ops) <supports_exec_events>: New
10870	member.
10871	(target_supports_exec_events): New macro.
10872	* win32-low.c (win32_target_ops) <supports_exec_events>:
10873	Initialize new member.
10874
108752015-09-09  Markus Metzger  <markus.t.metzger@intel.com>
10876
10877	* linux-low.c (linux_low_enable_btrace): Remove.
10878	(linux_target_ops): Replace linux_low_enable_btrace with
10879	linux_enable_btrace.
10880
108812015-09-03  Yao Qi  <yao.qi@linaro.org>
10882
10883	* linux-aarch64-low.c (aarch64_insert_point): Call
10884	aarch64_handle_watchpoint if aarch64_linux_region_ok_for_watchpoint
10885	returns true.
10886
108872015-08-27  Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
10888
10889	* linux-low.c (check_stopped_by_breakpoint): Use
10890	GDB_ARCH_IS_TRAP_BRKPT instead of GDB_ARCH_TRAP_BRKPT.
10891
108922015-08-27  Pedro Alves  <palves@redhat.com>
10893
10894	* proc-service.c (ps_pdwrite): Return PS_ERR/PS_OK explicily.
10895
108962015-08-26  Simon Marchi  <simon.marchi@ericsson.com>
10897
10898	* ax.c (gdb_parse_agent_expr): Replace xmalloc-family function with
10899	the XNEW-family equivalent.
10900	(compile_bytecodes): Likewise.
10901	* dll.c (loaded_dll): Likewise.
10902	* event-loop.c (append_callback_event): Likewise.
10903	(create_file_handler): Likewise.
10904	(create_file_event): Likewise.
10905	* hostio.c (handle_open): Likewise.
10906	* inferiors.c (add_thread): Likewise.
10907	(add_process): Likewise.
10908	* linux-aarch64-low.c (aarch64_linux_new_process): Likewise.
10909	* linux-arm-low.c (arm_new_process): Likewise.
10910	(arm_new_thread): Likewise.
10911	* linux-low.c (add_to_pid_list): Likewise.
10912	(linux_add_process): Likewise.
10913	(handle_extended_wait): Likewise.
10914	(add_lwp): Likewise.
10915	(enqueue_one_deferred_signal): Likewise.
10916	(enqueue_pending_signal): Likewise.
10917	(linux_resume_one_lwp_throw): Likewise.
10918	(linux_resume_one_thread): Likewise.
10919	(linux_read_memory): Likewise.
10920	(linux_write_memory): Likewise.
10921	* linux-mips-low.c (mips_linux_new_process): Likewise.
10922	(mips_linux_new_thread): Likewise.
10923	(mips_add_watchpoint): Likewise.
10924	* linux-x86-low.c (initialize_low_arch): Likewise.
10925	* lynx-low.c (lynx_add_process): Likewise.
10926	* mem-break.c (set_raw_breakpoint_at): Likewise.
10927	(set_breakpoint): Likewise.
10928	(add_condition_to_breakpoint): Likewise.
10929	(add_commands_to_breakpoint): Likewise.
10930	(clone_agent_expr): Likewise.
10931	(clone_one_breakpoint): Likewise.
10932	* regcache.c (new_register_cache): Likewise.
10933	* remote-utils.c (look_up_one_symbol): Likewise.
10934	* server.c (queue_stop_reply): Likewise.
10935	(start_inferior): Likewise.
10936	(queue_stop_reply_callback): Likewise.
10937	(handle_target_event): Likewise.
10938	* spu-low.c (fetch_ppc_memory): Likewise.
10939	(store_ppc_memory): Likewise.
10940	* target.c (set_target_ops): Likewise.
10941	* thread-db.c (thread_db_load_search): Likewise.
10942	(try_thread_db_load_1): Likewise.
10943	* tracepoint.c (add_tracepoint): Likewise.
10944	(add_tracepoint_action): Likewise.
10945	(create_trace_state_variable): Likewise.
10946	(cmd_qtdpsrc): Likewise.
10947	(cmd_qtro): Likewise.
10948	(add_while_stepping_state): Likewise.
10949	* win32-low.c (child_add_thread): Likewise.
10950	(get_image_name): Likewise.
10951
109522015-08-25  Yao Qi  <yao.qi@linaro.org>
10953
10954	* linux-aarch64-low.c (aarch64_linux_new_thread): Remove.
10955
109562015-08-25  Yao Qi  <yao.qi@linaro.org>
10957
10958	* Makefile.in (aarch64-linux.o): New rule.
10959	* configure.srv (aarch64*-*-linux*): Append aarch64-linux.o to
10960	srv_tgtobj.
10961	* linux-aarch64-low.c: Include nat/aarch64-linux.h.
10962	(aarch64_init_debug_reg_state): Make it extern.
10963	(aarch64_linux_prepare_to_resume): Remove.
10964
109652015-08-25  Yao Qi  <yao.qi@linaro.org>
10966
10967	* linux-aarch64-low.c (aarch64_linux_prepare_to_resume): Use
10968	lwp_arch_private_info and ptid_of_lwp.
10969
109702015-08-25  Yao Qi  <yao.qi@linaro.org>
10971
10972	* linux-aarch64-low.c (aarch64_get_debug_reg_state): Add argument pid.
10973	Find proc_info by find_process_pid.  All callers updated.
10974
109752015-08-25  Yao Qi  <yao.qi@linaro.org>
10976
10977	* linux-aarch64-low.c (struct arch64_dr_update_callback_param):
10978	Remove.
10979	(debug_reg_change_callback): Remove.
10980	(aarch64_notify_debug_reg_change): Remove.
10981
109822015-08-25  Yao Qi  <yao.qi@linaro.org>
10983
10984	* linux-aarch64-low.c (aarch64_notify_debug_reg_change):
10985	Call current_lwp_ptid.
10986
109872015-08-25  Yao Qi  <yao.qi@linaro.org>
10988
10989	* linux-aarch64-low.c (debug_reg_change_callback): Use
10990	debug_printf.
10991
109922015-08-25  Yao Qi  <yao.qi@linaro.org>
10993
10994	* linux-aarch64-low.c (debug_reg_change_callback): Use phex.
10995
109962015-08-25  Yao Qi  <yao.qi@linaro.org>
10997
10998	* linux-aarch64-low.c (debug_reg_change_callback): Remove comments.
10999
110002015-08-25  Yao Qi  <yao.qi@linaro.org>
11001
11002	* linux-aarch64-low.c (debug_reg_change_callback): Re-indent
11003	the code.
11004
110052015-08-25  Yao Qi  <yao.qi@linaro.org>
11006
11007	* linux-aarch64-low.c (aarch64_dr_update_callback_param) <pid>:
11008	Remove.
11009	(debug_reg_change_callback): Remove argument entry and add argument
11010	lwp.  Remove local variable thread.  Don't print thread id in the
11011	debugging output.  Don't check whether pid of thread equals to pid.
11012	(aarch64_notify_debug_reg_change): Don't set param.pid.  Call
11013	iterate_over_lwps instead find_inferior.
11014
110152015-08-24  Pedro Alves  <palves@redhat.com>
11016
11017	* inferiors.c (get_first_process): New function.
11018	* inferiors.h (get_first_process): New declaration.
11019	* remote-utils.c (read_ptid): Default to the first process in the
11020	list, instead of to the current thread's process.
11021
110222015-08-24  Pedro Alves  <palves@redhat.com>
11023
11024	* debug.c: Include gdb_sys_time.h instead of sys/time.h.
11025	* event-loop.c: Likewise.
11026	* remote-utils.c: Likewise.
11027	* tracepoint.c: Likewise.
11028
110292015-08-24  Pedro Alves  <palves@redhat.com>
11030
11031	* spu-low.c (spu_request_interrupt): Use lwpid_of instead of
11032	ptid_get_lwp.
11033
110342015-08-21  Pedro Alves  <palves@redhat.com>
11035
11036	* ax.c (gdb_eval_agent_expr): Return expr_eval_unhandled_opcode
11037	instead of literal 1.
11038
110392015-08-21  Pedro Alves  <palves@redhat.com>
11040
11041	* tdesc.c (default_description): Explicitly zero-initialize.
11042
110432015-08-21  Pedro Alves  <palves@redhat.com>
11044
11045	PR gdb/18749
11046	* inferiors.c (remove_thread): Discard any pending stop reply for
11047	this thread.
11048	* server.c (remove_all_on_match_pid): Rename to ...
11049	(remove_all_on_match_ptid): ... this.  Work with a filter ptid
11050	instead of a pid.
11051	(discard_queued_stop_replies): Change parameter to a ptid.  Now
11052	extern.
11053	(handle_v_kill, kill_inferior_callback, captured_main)
11054	(process_serial_event): Adjust.
11055	* server.h (discard_queued_stop_replies): Declare.
11056
110572015-08-21  Pedro Alves  <palves@redhat.com>
11058
11059	* linux-low.c (wait_for_sigstop): Always switch to no thread
11060	selected if the previously current thread dies.
11061	* lynx-low.c (lynx_request_interrupt): Use the first thread's
11062	process instead of the current thread's.
11063	* remote-utils.c (input_interrupt): Don't check if there's no
11064	current thread.
11065	* server.c (gdb_read_memory, gdb_write_memory): If setting the
11066	current thread to the general thread fails, error out.
11067	(handle_qxfer_auxv, handle_qxfer_libraries)
11068	(handle_qxfer_libraries_svr4, handle_qxfer_siginfo)
11069	(handle_qxfer_spu, handle_qxfer_statictrace, handle_qxfer_fdpic)
11070	(handle_query): Check if there's a thread selected instead of
11071	checking whether there's any thread in the thread list.
11072	(handle_qxfer_threads, handle_qxfer_btrace)
11073	(handle_qxfer_btrace_conf): Don't error out early if there's no
11074	thread in the thread list.
11075	(handle_v_cont, myresume): Don't set the current thread to the
11076	continue thread.
11077	(process_serial_event) <Hg handling>: Also set thread_id if the
11078	previous general thread is still alive.
11079	(process_serial_event) <g/G handling>: If setting the current
11080	thread to the general thread fails, error out.
11081	* spu-low.c (spu_resume, spu_request_interrupt): Use the first
11082	thread's lwp instead of the current thread's.
11083	* target.c (set_desired_thread): If the desired thread was not
11084	found, leave the current thread pointing to NULL.  Return an int
11085	(boolean) indicating success.
11086	* target.h (set_desired_thread): Change return type to int.
11087
110882015-08-20  Max Filippov  <jcmvbkbc@gmail.com>
11089
11090	* configure.srv (xtensa*-*-linux*): Add srv_linux_thread_db=yes.
11091	* linux-xtensa-low.c (arch/xtensa.h gdb_proc_service.h): New
11092	#includes.
11093	(ps_get_thread_area): New function.
11094
110952015-08-19  Gary Benson  <gbenson@redhat.com>
11096
11097	* hostio.c (handle_pread): Do not attempt to read more data
11098	than hostio_reply_with_data can fit in a packet.
11099
111002015-08-18  Joel Brobecker  <brobecker@adacore.com>
11101
11102	* linux-aarch32-low.c (NT_ARM_VFP): Define if not already defined.
11103
111042015-08-14  Matthew Fortune  <matthew.fortune@imgtec.com>
11105
11106	* linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP_REL.
11107
111082015-08-06  Pedro Alves  <palves@redhat.com>
11109
11110	* tracepoint.c (expr_eval_result): Now an int.
11111
111122015-08-06  Pedro Alves  <palves@redhat.com>
11113
11114	* gdbthread.h (struct regcache): Forward declare.
11115	(struct thread_info) <regcache_data>: Now a struct regcache
11116	pointer.
11117	* inferiors.c (inferior_regcache_data)
11118	(set_inferior_regcache_data): Now work with struct regcache
11119	pointers.
11120	* inferiors.h (struct regcache): Forward declare.
11121	(inferior_regcache_data, set_inferior_regcache_data): Now work
11122	with struct regcache pointers.
11123	* regcache.c (get_thread_regcache, regcache_invalidate_thread)
11124	(free_register_cache_thread): Remove struct regcache pointer
11125	casts.
11126
111272015-08-06  Pedro Alves  <palves@redhat.com>
11128
11129	* server.c (captured_main): On error, print the exception message
11130	to stderr, and if run_once is set, throw a quit.
11131
111322015-08-06  Pedro Alves  <palves@redhat.com>
11133
11134	* linux-low.c (move_out_of_jump_pad_callback): Temporarily switch
11135	the current thread.
11136
111372015-08-06  Pedro Alves  <palves@redhat.com>
11138
11139	* linux-low.c (linux_write_memory): Rewrite debug output to avoid
11140	reading beyond the passed in buffer length.
11141
111422015-08-06  Pierre Langlois  <pierre.langlois@arm.com>
11143
11144	* tracepoint.c (symbol_list) <required>: Remove.
11145
111462015-08-06  Pedro Alves  <palves@redhat.com>
11147
11148	* linux-low.c (handle_extended_wait): Set the fork child's suspend
11149	count if stopping and suspending threads.
11150	(check_stopped_by_breakpoint): If stopped by trace, set the LWP's
11151	stop reason to TARGET_STOPPED_BY_SINGLE_STEP.
11152	(linux_detach): Complete an ongoing step-over.
11153	(lwp_suspended_inc, lwp_suspended_decr): New functions.  Use
11154	throughout.
11155	(resume_stopped_resumed_lwps): Don't resume a suspended thread.
11156	(linux_wait_1): If passing a signal to the inferior after
11157	finishing a step-over, unsuspend and re-resume all lwps.  If we
11158	see a single-step event but the thread should be continuing, don't
11159	pass the trap to gdb.
11160	(stuck_in_jump_pad_callback, move_out_of_jump_pad_callback): Use
11161	internal_error instead of gdb_assert.
11162	(enqueue_pending_signal): New function.
11163	(check_ptrace_stopped_lwp_gone): Add debug output.
11164	(start_step_over): Use internal_error instead of gdb_assert.
11165	(complete_ongoing_step_over): New function.
11166	(linux_resume_one_thread): Don't resume a suspended thread.
11167	(proceed_one_lwp): If the LWP is stepping over a breakpoint, reset
11168	it stepping.
11169
111702015-08-06  Pedro Alves  <palves@redhat.com>
11171
11172	* linux-low.c (add_lwp): Set waitstatus to TARGET_WAITKIND_IGNORE.
11173	(linux_thread_alive): Use lwp_is_marked_dead.
11174	(extended_event_reported): Delete.
11175	(linux_wait_1): Check if waitstatus is TARGET_WAITKIND_IGNORE
11176	instead of extended_event_reported.
11177	(mark_lwp_dead): Don't set the 'dead' flag.  Store the waitstatus
11178	as well.
11179	(lwp_is_marked_dead): New function.
11180	(lwp_running): Use lwp_is_marked_dead.
11181	* linux-low.h: Delete 'dead' field, and update 'waitstatus's
11182	comment.
11183
111842015-08-06  Pedro Alves  <palves@redhat.com>
11185
11186	* linux-low.c (linux_wait_1): Move fork event output out of the
11187	!report_to_gdb check.  Pass event_child->waitstatus to
11188	target_waitstatus_to_string instead of ourstatus.
11189
111902015-08-04  Yao Qi  <yao.qi@linaro.org>
11191
11192	* linux-aarch64-low.c (aarch64_supports_tracepoints): Return 0
11193	if current_thread is 32 bit.
11194
111952015-08-04  Yao Qi  <yao.qi@linaro.org>
11196
11197	* linux-aarch64-low.c (aarch64_supports_z_point_type): Return
11198	0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
11199	* server.c (extended_protocol): Remove "static".
11200	* server.h (extended_protocol): Declare it.
11201
112022015-08-04  Yao Qi  <yao.qi@linaro.org>
11203
11204	* linux-aarch64-low.c (aarch64_get_pc): Get PC register on
11205	both aarch64 and aarch32.
11206	(aarch64_set_pc): Likewise.
11207
112082015-08-04  Yao Qi  <yao.qi@linaro.org>
11209
11210	* configure.srv (case aarch64*-*-linux*): Append arm-with-neon.o
11211	to srv_regobj and append arm-core.xml arm-vfpv3.xml and
11212	arm-with-neon.xml to srv_xmlfiles.
11213	* linux-aarch64-low.c: Include linux-aarch32-low.h.
11214	(is_64bit_tdesc): New function.
11215	(aarch64_linux_read_description): New function.
11216	(aarch64_arch_setup): Call aarch64_linux_read_description.
11217	(regs_info): Rename to regs_info_aarch64.
11218	(aarch64_regs_info): Return right regs_info.
11219	(initialize_low_arch): Call initialize_low_arch_aarch32.
11220
112212015-08-04  Yao Qi  <yao.qi@linaro.org>
11222
11223	* configure.srv (srv_tgtobj): Add linux-aarch32-low.o.
11224	* linux-aarch32-low.c: New file.
11225	* linux-aarch32-low.h: New file.
11226	* linux-arm-low.c (arm_fill_gregset): Move it to
11227	linux-aarch32-low.c.
11228	(arm_store_gregset): Likewise.
11229	(arm_fill_vfpregset): Call arm_fill_vfpregset_num
11230	(arm_store_vfpregset): Call arm_store_vfpregset_num.
11231	(arm_arch_setup): Check if PTRACE_GETREGSET works.
11232	(regs_info): Rename to regs_info_arm.
11233	(arm_regs_info): Return regs_info_aarch32 if
11234	have_ptrace_getregset is 1 and target description is
11235	arm_with_neon or arm_with_vfpv3.
11236	(initialize_low_arch): Don't call init_registers_arm_with_neon.
11237	Call initialize_low_arch_aarch32 instead.
11238
112392015-08-04  Yao Qi  <yao.qi@linaro.org>
11240
11241	* linux-x86-low.c (have_ptrace_getregset): Move it to ...
11242	* linux-low.c: ... here.
11243	* linux-low.h (have_ptrace_getregset): Declare it.
11244
112452015-08-04  Pedro Alves  <palves@redhat.com>
11246
11247	* thread-db.c (struct thread_db): Use new typedefs.
11248	(try_thread_db_load_1): Define local TDB_DLSYM macro and use it in
11249	CHK calls.
11250	(disable_thread_event_reporting): Cast result of dlsym to
11251	destination function pointer type.
11252	(thread_db_mourn): Use td_ta_delete_ftype.
11253
112542015-08-03  Sandra Loosemore  <sandra@codesourcery.com>
11255
11256	* linux-nios2-low.c (NIOS2_BREAKPOINT): Conditionalize for
11257	arch variant.
11258	(CDX_BREAKPOINT): Define for R2.
11259	(nios2_breakpoint_at): Check for CDX_BREAKPOINT when R2.
11260	(the_low_target): Add comments.
11261
112622015-07-30  Yao Qi  <yao.qi@linaro.org>
11263
11264	* linux-arm-low.c (arm_hwcap): Remove it.
11265	(arm_read_description): New local variable arm_hwcap.  Don't
11266	set arm_hwcap to zero.
11267
112682015-07-30  Yao Qi  <yao.qi@linaro.org>
11269
11270	* linux-arm-low.c (arm_fill_wmmxregset): Don't use arm_hwcap.
11271	Use regcache->tdesc instead.
11272	(arm_store_wmmxregset): Likewise.
11273	(arm_fill_vfpregset): Likewise.
11274	(arm_store_vfpregset): Likewise.
11275
112762015-07-30  Yao Qi  <yao.qi@linaro.org>
11277
11278	* linux-arm-low.c: Include arch/arm.h.
11279	(arm_fill_gregset): Don't use arm_num_regs and arm_regmap.
11280	(arm_store_gregset): Likewise.
11281
112822015-07-29  Simon Marchi  <simon.marchi@ericsson.com>
11283
11284	* linux-mips-low.c (mips_linux_prepare_to_resume): Add NULL as
11285	ptrace's 4th parameter.
11286
112872015-07-27  Yao Qi  <yao.qi@linaro.org>
11288
11289	* configure.srv (case aarch64*-*-linux*): Don't set
11290	srv_linux_usrregs.
11291
112922015-07-24  Pedro Alves  <palves@redhat.c: Likewise.om>
11293
11294	* linux-aarch64-low.c: Include nat/gdb_ptrace.h instead of
11295	sys/ptrace.h.
11296	* linux-arm-low.c: Likewise.
11297	* linux-cris-low.c: Likewise.
11298	* linux-crisv32-low.c: Likewise.
11299	* linux-low.c: Likewise.
11300	* linux-m68k-low.c: Likewise.
11301	* linux-mips-low.c: Likewise.
11302	* linux-nios2-low.c: Likewise.
11303	* linux-s390-low.c: Likewise.
11304	* linux-sparc-low.c: Likewise.
11305	* linux-tic6x-low.c: Likewise.
11306	* linux-tile-low.c: Likewise.
11307	* linux-x86-low.c: Likewise.
11308
113092015-07-24  Pedro Alves  <palves@redhat.com>
11310
11311	* config.in: Regenerate.
11312	* configure: Regenerate.
11313
113142015-07-24  Pedro Alves  <palves@redhat.com>
11315
11316	* acinclude.m4: Include ../ptrace.m4.
11317	* configure.ac: Call GDB_AC_PTRACE.
11318	* config.in, configure: Regenerate.
11319
113202015-07-24  Yao Qi  <yao.qi@linaro.org>
11321
11322	* linux-low.c (linux_create_inferior): Remove setting to
11323	proc->priv->new_inferior.
11324	(linux_attach): Likewise.
11325	(linux_low_filter_event): Likewise.
11326	* linux-low.h (struct process_info_private) <new_inferior>: Remove.
11327
113282015-07-24  Yao Qi  <yao.qi@linaro.org>
11329
11330	* linux-low.c (linux_arch_setup): New function.
11331	(linux_low_filter_event): If proc->tdesc is NULL and
11332	proc->attached is true, call the_low_target.arch_setup.
11333	Otherwise, keep status pending, and return.
11334	(linux_resume_one_lwp_throw): Don't call get_pc if
11335	thread->while_stepping isn't NULL.  Don't call
11336	get_thread_regcache if proc->tdesc is NULL.
11337	(need_step_over_p): Return 0 if proc->tdesc is NULL.
11338	(linux_target_ops): Install arch_setup.
11339	* server.c (start_inferior): Call the_target->arch_setup.
11340	* target.h (struct target_ops) <arch_setup>: New field.
11341	(target_arch_setup): New marco.
11342	* lynx-low.c (lynx_target_ops): Update.
11343	* nto-low.c (nto_target_ops): Update.
11344	* spu-low.c (spu_target_ops): Update.
11345	* win32-low.c (win32_target_ops): Update.
11346
113472015-07-24  Yao Qi  <yao.qi@linaro.org>
11348
11349	* linux-low.c (linux_add_process): Don't set
11350	proc->priv->new_inferior.
11351	(linux_create_inferior): Set proc->priv->new_inferior to 1.
11352	(linux_attach): Likewise.
11353
113542015-07-24  Yao Qi  <yao.qi@linaro.org>
11355
11356	* server.c (start_inferior): Code refactor.
11357
113582015-07-24  Yao Qi  <yao.qi@linaro.org>
11359
11360	* server.c (process_serial_event): Set general_thread.
11361
113622015-07-21  Yao Qi  <yao.qi@linaro.org>
11363
11364	* linux-aarch64-low.c (aarch64_arch_setup): Remove code and call
11365	aarch64_linux_get_debug_reg_capacity.
11366
113672015-07-17  Yao Qi  <yao.qi@linaro.org>
11368
11369	* Makefile.in (aarch64-linux-hw-point.o): New rule.
11370	* configure.srv (srv_tgtobj): Append aarch64-linux-hw-point.o.
11371	* linux-aarch64-low.c: Include nat/aarch64-linux-hw-point.h.
11372	(AARCH64_HBP_MAX_NUM): Move to nat/aarch64-linux-hw-point.h.
11373	(AARCH64_HWP_MAX_NUM, AARCH64_HBP_ALIGNMENT): Likewise.
11374	(AARCH64_HWP_ALIGNMENT): Likewise.
11375	(AARCH64_HWP_MAX_LEN_PER_REG): Likewise.
11376	(AARCH64_DEBUG_NUM_SLOTS, AARCH64_DEBUG_ARCH): Likewise.
11377	(aarch64_num_bp_regs, aarch64_num_wp_regs): Likewise.
11378	(AARCH64_DEBUG_ARCH_V8, DR_MARK_ALL_CHANGED): Likewise.
11379	(DR_MARK_N_CHANGED, DR_CLEAR_CHANGED): Likewise.
11380	(DR_HAS_CHANGED, DR_N_HAS_CHANGE): Likewise.
11381	(struct aarch64_debug_reg_state): Likewise.
11382	(struct arch_lwp_info):	Likewise.
11383	(aarch64_align_watchpoint): Likewise.
11384	(DR_CONTROL_ENABLED, DR_CONTROL_LENGTH): Likewise.
11385	(aarch64_watchpoint_length): Likewise.
11386	(aarch64_point_encode_ctrl_reg): Likewise
11387	(aarch64_point_is_aligned): Likewise.
11388	(aarch64_align_watchpoint): Likewise.
11389	(aarch64_linux_set_debug_regs):
11390	(aarch64_dr_state_insert_one_point): Likewise.
11391	(aarch64_dr_state_remove_one_point): Likewise.
11392	(aarch64_handle_breakpoint): Likewise.
11393	(aarch64_handle_aligned_watchpoint): Likewise.
11394	(aarch64_handle_unaligned_watchpoint): Likewise.
11395	(aarch64_handle_watchpoint): Likewise.
11396
113972015-07-17  Yao Qi  <yao.qi@linaro.org>
11398
11399	* linux-aarch64-low.c (aarch64_handle_breakpoint): Add argument state
11400	and don't aarch64_get_debug_reg_state.  All callers update.
11401	(aarch64_handle_aligned_watchpoint): Likewise.
11402	(aarch64_handle_unaligned_watchpoint): Likewise.
11403	(aarch64_handle_watchpoint): Likewise.
11404	(aarch64_insert_point): Call aarch64_get_debug_reg_state earlier.
11405	(aarch64_remove_point): Likewise.
11406
114072015-07-17  Yao Qi  <yao.qi@linaro.org>
11408
11409	* linux-aarch64-low.c (aarch64_show_debug_reg_state): Use
11410	debug_printf.
11411	(aarch64_handle_unaligned_watchpoint): Likewise.
11412
114132015-07-15  Jan Kratochvil  <jan.kratochvil@redhat.com>
11414
11415	Revert the previous 3 commits:
11416	Move gdb_regex* to common/
11417	Move linux_find_memory_regions_full & co.
11418	gdbserver build-id attribute generator
11419
114202015-07-15  Aleksandar Ristovski  <aristovski@qnx.com
11421	    Jan Kratochvil  <jan.kratochvil@redhat.com>
11422
11423	gdbserver build-id attribute generator.
11424	* linux-low.c (nat/linux-maps.h, search.h, rsp-low.h): Include.
11425	(ElfXX_Ehdr, ElfXX_Phdr, ElfXX_Nhdr): New.
11426	(ELFXX_FLD, ELFXX_SIZEOF, ELFXX_ROUNDUP, BUILD_ID_INVALID): New.
11427	(find_phdr): New.
11428	(get_dynamic): Use find_pdhr to traverse program headers.
11429	(struct mapping_entry, mapping_entry_s, free_mapping_entry_vec)
11430	(compare_mapping_entry_range, struct find_memory_region_callback_data)
11431	(read_build_id, find_memory_region_callback, lrfind_mapping_entry)
11432	(get_hex_build_id): New.
11433	(linux_qxfer_libraries_svr4): Add optional build-id attribute
11434	to reply XML document.
11435
114362015-07-15  Aleksandar Ristovski  <aristovski@qnx.com
11437	    Jan Kratochvil  <jan.kratochvil@redhat.com>
11438
11439	* target.c: Include target/target-utils.h and fcntl.h.
11440	(target_fileio_read_stralloc_1_pread, target_fileio_read_stralloc_1)
11441	(target_fileio_read_stralloc): New functions.
11442
114432015-07-15  Jan Kratochvil  <jan.kratochvil@redhat.com>
11444
11445	* Makefile.in (OBS): Add gdb_regex.o.
11446	(gdb_regex.o): New.
11447	* config.in: Rebuilt.
11448	* configure: Rebuilt.
11449
114502015-07-15  Aleksandar Ristovski  <aristovski@qnx.com
11451	    Jan Kratochvil  <jan.kratochvil@redhat.com>
11452
11453	Create empty nat/linux-maps.[ch] and common/target-utils.[ch].
11454	* Makefile.in (OBS): Add target-utils.o.
11455	(linux-maps.o, target-utils.o): New.
11456	* configure.srv (srv_linux_obj): Add linux-maps.o.
11457
114582015-07-15  Pierre Langlois  <pierre.langlois@arm.com>
11459
11460	* linux-aarch64-low.c (aarch64_supports_range_stepping): New
11461	function, return 1.
11462	(the_low_target): Install it.
11463
114642015-07-14  Pedro Alves  <palves@redhat.com>
11465
11466	* linux-low.c (kill_wait_lwp): Don't assert if waitpid fails.
11467	Instead, ignore ECHILD, and throw an error for other errnos.
11468
114692015-07-10  Pedro Alves  <palves@redhat.com>
11470
11471	* event-loop.c (struct callback_event) <data>: Change type to
11472	gdb_client_data instance instead of gdb_client_data pointer.
11473	(append_callback_event): Adjust.
11474
114752015-07-10  Pierre Langlois  <pierre.langlois@arm.com>
11476
11477	* linux-aarch64-low.c: Add comments for each linux_target_ops
11478	method.  Remove comments already covered in target_ops and
11479	linux_target_ops definitions.
11480	(the_low_target): Add comments for each unimplemented method.
11481
114822015-07-09  Yao Qi  <yao.qi@linaro.org>
11483
11484	* linux-aarch64-low.c (aarch64_regmap): Remove.
11485	(aarch64_usrregs_info): Remove.
11486	(regs_info): Set field usrregs to NULL.
11487
114882015-07-02  Markus Metzger  <markus.t.metzger@intel.com>
11489
11490	* linux-low.c: Include "rsp-low.h"
11491	(linux_low_encode_pt_config, linux_low_encode_raw): New.
11492	(linux_low_read_btrace): Support BTRACE_FORMAT_PT.
11493	(linux_low_btrace_conf): Support BTRACE_FORMAT_PT.
11494	(handle_btrace_enable_pt): New.
11495	(handle_btrace_general_set): Support "pt".
11496	(handle_btrace_conf_general_set): Support "pt:size".
11497
114982015-06-29  Pierre Langlois  <pierre.langlois@arm.com>
11499
11500	* linux-aarch64-low.c (aarch64_supports_z_point_type): Enable for
11501	Z_PACKET_SW_BP.
11502
115032015-06-29  Pierre Langlois  <pierre.langlois@arm.com>
11504
11505	* linux-aarch64-low.c: Remove comment about endianness.
11506	(aarch64_breakpoint): Change type to gdb_byte[].  Set to "brk #0".
11507	(aarch64_breakpoint_at): Change type of insn to gdb_byte[].  Use
11508	memcmp.
11509
115102015-06-24  Gary Benson  <gbenson@redhat.com>
11511
11512	* linux-i386-ipa.c (stdint.h): Do not include.
11513	* lynx-i386-low.c (stdint.h): Likewise.
11514	* lynx-ppc-low.c (stdint.h): Likewise.
11515	* mem-break.c (stdint.h): Likewise.
11516	* thread-db.c (stdint.h): Likewise.
11517	* tracepoint.c (stdint.h): Likewise.
11518	* win32-low.c (stdint.h): Likewise.
11519
115202015-06-18  Simon Marchi  <simon.marchi@ericsson.com>
11521
11522	* server.c (write_qxfer_response): Update call to
11523	remote_escape_output.
11524
115252015-06-15  Aleksandar Ristovski  <aristovski@qnx.com
11526	    Jan Kratochvil  <jan.kratochvil@redhat.com>
11527
11528	Merge multiple hex conversions.
11529	* gdbreplay.c (tohex): Rename to 'fromhex'.
11530	(logchar): Use fromhex.
11531
115322015-06-10  Jan Kratochvil  <jan.kratochvil@redhat.com>
11533
11534	* server.c (handle_qxfer_libraries): Set `version' attribute for
11535	<library-list>.
11536
115372015-06-10  Gary Benson  <gbenson@redhat.com>
11538
11539	* target.h (struct target_ops) <multifs_open>: New field.
11540	<multifs_unlink>: Likewise.
11541	<multifs_readlink>: Likewise.
11542	* linux-low.c (nat/linux-namespaces.h): New include.
11543	(linux_target_ops): Initialize the_target->multifs_open,
11544	the_target->multifs_unlink and the_target->multifs_readlink.
11545	* hostio.h (hostio_handle_new_gdb_connection): New declaration.
11546	* hostio.c (hostio_fs_pid): New static variable.
11547	(hostio_handle_new_gdb_connection): New function.
11548	(handle_setfs): Likewise.
11549	(handle_open): Use the_target->multifs_open as appropriate.
11550	(handle_unlink): Use the_target->multifs_unlink as appropriate.
11551	(handle_readlink): Use the_target->multifs_readlink as
11552	appropriate.
11553	(handle_vFile): Handle vFile:setfs packets.
11554	* server.c (handle_query): Call hostio_handle_new_gdb_connection
11555	after target_handle_new_gdb_connection.
11556
115572015-06-10  Gary Benson  <gbenson@redhat.com>
11558
11559	* configure.ac (AC_CHECK_FUNCS): Add setns.
11560	* config.in: Regenerate.
11561	* configure: Likewise.
11562	* Makefile.in (SFILES): Add nat/linux-namespaces.c.
11563	(linux-namespaces.o): New rule.
11564	* configure.srv (srv_linux_obj): Add linux-namespaces.o.
11565
115662015-06-09  Gary Benson <gbenson@redhat.com>
11567
11568	* hostio.c (handle_open): Process mode argument with
11569	fileio_to_host_mode.
11570
115712015-06-01  Yao Qi  <yao.qi@linaro.org>
11572
11573	* linux-s390-low.c (PTRACE_GETREGSET, PTRACE_SETREGSET): Remove.
11574	* linux-x86-low.c: Likewise.
11575
115762015-05-28  Don Breazeal  <donb@codesourcery.com>
11577
11578	* linux-low.c (handle_extended_wait): Initialize
11579	thread_info.last_resume_kind for new fork children.
11580
115812015-05-15  Pedro Alves  <palves@redhat.com>
11582
11583	* target.h (target_handle_new_gdb_connection): Rewrite using if
11584	wrapped in do/while.
11585
115862015-05-14  Joel Brobecker  <brobecker@adacore.com>
11587
11588	* configure.ac: Add prfpregset_t BFD_HAVE_SYS_PROCFS_TYPE check.
11589	* configure, config.in: Regenerate.
11590	* gdb_proc_service.h [HAVE_PRFPREGSET_T] (prfpregset_t):
11591	Declare typedef.
11592
115932015-05-12  Don Breazeal  <donb@codesourcery.com>
11594
11595	* linux-low.c (handle_extended_wait): Handle PTRACE_EVENT_FORK and
11596	PTRACE_EVENT_VFORK_DONE.
11597	(linux_low_ptrace_options, extended_event_reported): Add vfork
11598	events.
11599	* remote-utils.c (prepare_resume_reply): New stop reasons "vfork"
11600	and "vforkdone" for RSP 'T' Stop Reply Packet.
11601	* server.h (report_vfork_events): Declare
11602	global variable.
11603
116042015-05-12  Don Breazeal  <donb@codesourcery.com>
11605
11606	* linux-aarch64-low.c (aarch64_linux_new_fork): New function.
11607	(the_low_target) <new_fork>: Initialize new member.
11608	* linux-arm-low.c (arm_new_fork): New function.
11609	(the_low_target) <new_fork>: Initialize new member.
11610	* linux-low.c (handle_extended_wait): Call new target function
11611	new_fork.
11612	* linux-low.h (struct linux_target_ops) <new_fork>: New member.
11613	* linux-mips-low.c (mips_add_watchpoint): New function
11614	extracted from mips_insert_point.
11615	(the_low_target) <new_fork>: Initialize new member.
11616	(mips_linux_new_fork): New function.
11617	(mips_insert_point): Call mips_add_watchpoint.
11618	* linux-x86-low.c (x86_linux_new_fork): New function.
11619	(the_low_target) <new_fork>: Initialize new member.
11620
116212015-05-12  Don Breazeal  <donb@codesourcery.com>
11622
11623	* linux-low.c (handle_extended_wait): Implement return value,
11624	rename argument 'event_child' to 'event_lwp', handle
11625	PTRACE_EVENT_FORK, call internal_error for unrecognized event.
11626	(linux_low_ptrace_options): New function.
11627	(linux_low_filter_event): Call linux_low_ptrace_options,
11628	use different argument fo linux_enable_event_reporting,
11629	use return value from handle_extended_wait.
11630	(extended_event_reported): New function.
11631	(linux_wait_1): Call extended_event_reported and set
11632	status to report fork events.
11633	(linux_write_memory): Add pid to debug message.
11634	(reset_lwp_ptrace_options_callback): New function.
11635	(linux_handle_new_gdb_connection): New function.
11636	(linux_target_ops): Initialize new structure member.
11637	* linux-low.h (struct lwp_info) <waitstatus>: New member.
11638	* lynx-low.c: Initialize new structure member.
11639	* remote-utils.c (prepare_resume_reply): Implement stop reason
11640	"fork" for "T" stop message.
11641	* server.c (handle_query): Call handle_new_gdb_connection.
11642	* server.h (report_fork_events): Declare global flag.
11643	* target.h (struct target_ops) <handle_new_gdb_connection>:
11644	New member.
11645	(target_handle_new_gdb_connection): New macro.
11646	* win32-low.c: Initialize new structure member.
11647
116482015-05-12  Don Breazeal  <donb@codesourcery.com>
11649
11650	* mem-break.c (APPEND_TO_LIST): Define macro.
11651	(clone_agent_expr): New function.
11652	(clone_one_breakpoint): New function.
11653	(clone_all_breakpoints): New function.
11654	* mem-break.h: Declare new functions.
11655
116562015-05-12  Don Breazeal  <donb@codesourcery.com>
11657
11658	* linux-low.c (linux_supports_fork_events): New function.
11659	(linux_supports_vfork_events): New function.
11660	(linux_target_ops): Initialize new structure members.
11661	(initialize_low): Call linux_check_ptrace_features.
11662	* lynx-low.c (lynx_target_ops): Initialize new structure
11663	members.
11664	* server.c (report_fork_events, report_vfork_events):
11665	New global flags.
11666	(handle_query): Add new features to qSupported packet and
11667	response.
11668	(captured_main): Initialize new global variables.
11669	* target.h (struct target_ops) <supports_fork_events>:
11670	New member.
11671	<supports_vfork_events>: New member.
11672	(target_supports_fork_events): New macro.
11673	(target_supports_vfork_events): New macro.
11674	* win32-low.c (win32_target_ops): Initialize new structure
11675	members.
11676
116772015-05-12  Gary Benson <gbenson@redhat.com>
11678
11679	* server.c (handle_qxfer_exec_file): Use current process
11680	if annex is empty.
11681
116822015-05-08  Sandra Loosemore  <sandra@codesourcery.com>
11683
11684	* linux-nios2-low.c: Include elf/common.h.  Adjust comments.
11685	Remove HAVE_PTRACE_GETREGS conditionals.
11686	(nios2_regsets): Use PTRACE_GETREGSET and PTRACE_SETREGSET
11687	instead of PTRACE_GETREGS and PTRACE_SETREGS.
11688
116892015-05-08  Yao Qi  <yao.qi@linaro.org>
11690
11691	* linux-low.c (linux_supports_conditional_breakpoints): New
11692	function.
11693	(linux_target_ops): Install new target method.
11694	* lynx-low.c (lynx_target_ops): Install NULL hook for
11695	supports_conditional_breakpoints.
11696	* nto-low.c (nto_target_ops): Likewise.
11697	* spu-low.c (spu_target_ops): Likewise.
11698	* win32-low.c (win32_target_ops): Likewise.
11699	* server.c (handle_query): Check
11700	target_supports_conditional_breakpoints.
11701	* target.h (struct target_ops) <supports_conditional_breakpoints>:
11702	New field.
11703	(target_supports_conditional_breakpoints): New macro.
11704
117052015-05-06  Pedro Alves  <palves@redhat.com>
11706
11707	PR server/18081
11708	* server.c (start_inferior): If the process exits, mourn it.
11709
117102015-04-21  Gary Benson <gbenson@redhat.com>
11711
11712	* hostio.c (fileio_open_flags_to_host): Factored out to
11713	fileio_to_host_openflags in common/fileio.c.  Single use
11714	updated.
11715
117162015-04-17  Max Filippov  <jcmvbkbc@gmail.com>
11717
11718	* linux-xtensa-low.c (xtensa_fill_gregset)
11719	(xtensa_store_gregset): Check XCHAL_HAVE_LOOPS instead of
11720	XCHAL_HAVE_LOOP.
11721
117222015-04-17  Max Filippov  <jcmvbkbc@gmail.com>
11723
11724	* linux-xtensa-low.c (xtensa_usrregs_info): Remove.
11725	(regs_info): Replace usrregs pointer with NULL.
11726
117272015-04-17  Gary Benson  <gbenson@redhat.com>
11728
11729	* target.h (struct target_ops) <pid_to_exec_file>: New field.
11730	* linux-low.c (linux_target_ops): Initialize pid_to_exec_file.
11731	* server.c (handle_qxfer_exec_file): New function.
11732	(qxfer_packets): Add exec-file entry.
11733	(handle_query): Report qXfer:exec-file:read as supported packet.
11734
117352015-04-14  Romain Naour <romain.naour@openwide.fr>  (tiny change)
11736
11737	* linux-low.c (linux_read_offsets): Remove get_thread_lwp.
11738
117392015-04-09  Gary Benson <gbenson@redhat.com>
11740
11741	* hostio-errno.c (errno_to_fileio_error): Remove function.
11742	Update caller to use remote_fileio_to_fio_error.
11743
117442015-04-09  Yao Qi  <yao.qi@linaro.org>
11745
11746	* linux-low.c (linux_insert_point): Call
11747	insert_memory_breakpoint if TYPE is raw_bkpt_type_sw.
11748	(linux_remove_point): Call remove_memory_breakpoint if type is
11749	raw_bkpt_type_sw.
11750	* linux-x86-low.c (x86_insert_point): Don't call
11751	insert_memory_breakpoint.
11752	(x86_remove_point): Don't call remove_memory_breakpoint.
11753
117542015-04-01  Pedro Alves  <palves@redhat.com>
11755	    Cleber Rosa  <crosa@redhat.com>
11756
11757	* server.c (gdbserver_usage): Reorganize and extend the usage
11758	message.
11759
117602015-03-24  Pedro Alves  <palves@redhat.com>
11761
11762	* linux-low.c (check_stopped_by_breakpoint): Tweak debug log
11763	output.  Also dump TRAP_TRACE.
11764	(linux_low_filter_event): In debug output, distinguish a
11765	resume_stop SIGSTOP from a delayed SIGSTOP.
11766
117672015-03-24  Gary Benson  <gbenson@redhat.com>
11768
11769	* linux-x86-low.c (x86_linux_new_thread): Moved to
11770	nat/x86-linux.c.
11771	(x86_linux_prepare_to_resume): Likewise.
11772
117732015-03-24  Gary Benson  <gbenson@redhat.com>
11774
11775	* Makefile.in (x86-linux-dregs.o): New rule.
11776	* configure.srv: Add x86-linux-dregs.o to relevant targets.
11777	* linux-x86-low.c: Include nat/x86-linux-dregs.h.
11778	(u_debugreg_offset): Moved to nat/x86-linux-dregs.c.
11779	(x86_linux_dr_get): Likewise.
11780	(x86_linux_dr_set): Likewise.
11781	(update_debug_registers_callback): Likewise.
11782	(x86_linux_dr_set_addr): Likewise.
11783	(x86_linux_dr_get_addr): Likewise.
11784	(x86_linux_dr_set_control): Likewise.
11785	(x86_linux_dr_get_control): Likewise.
11786	(x86_linux_dr_get_status): Likewise.
11787	(x86_linux_update_debug_registers): Likewise.
11788
117892015-03-24  Gary Benson  <gbenson@redhat.com>
11790
11791	* linux-x86-low.c (x86_linux_update_debug_registers):
11792	New function, factored out from...
11793	(x86_linux_prepare_to_resume): ...this.
11794
117952015-03-24  Gary Benson  <gbenson@redhat.com>
11796
11797	* linux-x86-low.c (x86_linux_dr_get): Update comments.
11798	(x86_linux_dr_set): Likewise.
11799	(update_debug_registers_callback): Likewise.
11800	(x86_linux_dr_set_addr): Likewise.
11801	(x86_linux_dr_get_addr): Likewise.
11802	(x86_linux_dr_set_control): Likewise.
11803	(x86_linux_dr_get_control): Likewise.
11804	(x86_linux_dr_get_status): Likewise.
11805	(x86_linux_prepare_to_resume): Likewise.
11806
118072015-03-24  Gary Benson  <gbenson@redhat.com>
11808
11809	* linux-x86-low.c (x86_linux_dr_get): Add assertion.
11810	Use perror_with_name.  Pass string through gettext.
11811	(x86_linux_dr_set): Likewise.
11812
118132015-03-24  Gary Benson  <gbenson@redhat.com>
11814
11815	* linux-x86-low.c (x86_dr_low_set_addr): Rename to...
11816	(x86_linux_dr_set_addr): ...this.
11817	(x86_dr_low_get_addr): Rename to...
11818	(x86_linux_dr_get_addr): ...this.
11819	(x86_dr_low_set_control): Rename to...
11820	(x86_linux_dr_set_control): ...this.
11821	(x86_dr_low_get_control): Rename to...
11822	(x86_linux_dr_get_control): ...this.
11823	(x86_dr_low_get_status): Rename to...
11824	(x86_linux_dr_get_status): ...this.
11825	(x86_dr_low): Update with new function names.
11826
118272015-03-24  Gary Benson  <gbenson@redhat.com>
11828
11829	* Makefile.in (x86-linux.o): New rule.
11830	* configure.srv: Add x86-linux.o to relevant targets.
11831	* linux-low.c (lwp_set_arch_private_info): New function.
11832	(lwp_arch_private_info): Likewise.
11833	* linux-x86-low.c: Include nat/x86-linux.h.
11834	(arch_lwp_info): Removed structure.
11835	(update_debug_registers_callback):
11836	Use lwp_set_debug_registers_changed.
11837	(x86_linux_prepare_to_resume): Use lwp_debug_registers_changed
11838	and lwp_set_debug_registers_changed.
11839	(x86_linux_new_thread): Use lwp_set_debug_registers_changed.
11840
118412015-03-24  Gary Benson  <gbenson@redhat.com>
11842
11843	* linux-low.h (linux_target_ops) <new_thread>: Changed signature.
11844	* linux-arm-low.c (arm_new_thread): Likewise.
11845	* linux-aarch64-low.c (aarch64_linux_new_thread): Likewise.
11846	* linux-mips-low.c (mips_linux_new_thread): Likewise.
11847	* linux-x86-low.c (x86_linux_new_thread): Likewise.
11848	* linux-low.c (add_lwp): Update the_low_target.new_thread call.
11849
118502015-03-24  Gary Benson  <gbenson@redhat.com>
11851
11852	* linux-low.c (ptid_of_lwp): New function.
11853	(lwp_is_stopped): Likewise.
11854	(lwp_stop_reason): Likewise.
11855	* linux-x86-low.c (update_debug_registers_callback):
11856	Use lwp_is_stopped.
11857	(x86_linux_prepare_to_resume): Use ptid_of_lwp and
11858	lwp_stop_reason.
11859
118602015-03-24  Gary Benson  <gbenson@redhat.com>
11861
11862	* linux-low.h (linux_stop_lwp): Remove declaration.
11863
118642015-03-24  Gary Benson  <gbenson@redhat.com>
11865
11866	* linux-low.h: Include nat/linux-nat.h.
11867	* linux-low.c (iterate_over_lwps_args): New structure.
11868	(iterate_over_lwps_filter): New function.
11869	(iterate_over_lwps): Likewise.
11870	* linux-x86-low.c (update_debug_registers_callback):
11871	Update signature to what iterate_over_lwps expects.
11872	Remove PID check that iterate_over_lwps now performs.
11873	(x86_dr_low_set_addr): Use iterate_over_lwps.
11874	(x86_dr_low_set_control): Likewise.
11875
118762015-03-24  Gary Benson  <gbenson@redhat.com>
11877
11878	* linux-x86-low.c (x86_debug_reg_state): New function.
11879	(x86_linux_prepare_to_resume): Use the above.
11880
118812015-03-24  Gary Benson  <gbenson@redhat.com>
11882
11883	* linux-low.c (current_lwp_ptid): New function.
11884	* linux-x86-low.c: Include nat/linux-nat.h.
11885	(x86_dr_low_get_addr): Use current_lwp_ptid.
11886	(x86_dr_low_get_control): Likewise.
11887	(x86_dr_low_get_status): Likewise.
11888
118892015-03-20  Pedro Alves  <palves@redhat.com>
11890
11891	* tracepoint.c (cmd_qtstatus): Make "str" const.
11892
118932015-03-20  Pedro Alves  <palves@redhat.com>
11894
11895	* server.c (handle_general_set): Make "req_str" const.
11896
118972015-03-19  Pedro Alves  <palves@redhat.com>
11898
11899	* linux-low.c (linux_resume_one_lwp): Rename to ...
11900	(linux_resume_one_lwp_throw): ... this.  Don't handle ESRCH here,
11901	instead call perror_with_name.
11902	(check_ptrace_stopped_lwp_gone): New function.
11903	(linux_resume_one_lwp): Reimplement as wrapper around
11904	linux_resume_one_lwp_throw that swallows errors if the LWP is
11905	gone.
11906
119072015-03-19  Pedro Alves  <palves@redhat.com>
11908
11909	* linux-low.c (count_events_callback, select_event_lwp_callback):
11910	No longer check whether the thread has resume_stop as last resume
11911	kind.
11912
119132015-03-19 Pedro Alves  <palves@redhat.com>
11914
11915	* linux-low.c (count_events_callback, select_event_lwp_callback):
11916	Use the lwp's status_pending_p field, not the thread's.
11917
119182015-03-19  Pedro Alves  <palves@redhat.com>
11919
11920	* linux-low.c (select_event_lwp_callback): Update comments to
11921	no longer mention SIGTRAP.
11922
119232015-03-18  Gary Benson  <gbenson@redhat.com>
11924
11925	* server.c (handle_query): Do not report vFile:fstat as supported.
11926
119272015-03-11  Gary Benson  <gbenson@redhat.com>
11928
11929	* hostio.c (sys/types.h): New include.
11930	(sys/stat.h): Likewise.
11931	(common-remote-fileio.h): Likewise.
11932	(handle_fstat): New function.
11933	(handle_vFile): Handle vFile:fstat packets.
11934
119352015-03-11  Gary Benson  <gbenson@redhat.com>
11936
11937	* configure.ac (AC_CHECK_MEMBERS): Add checks for
11938	struct stat.st_blocks and struct stat.st_blksize.
11939	* configure: Regenerate.
11940	* config.in: Likewise.
11941	* Makefile.in (SFILES): Add common/common-remote-fileio.c.
11942	(OBS): Add common-remote-fileio.o.
11943	(common-remote-fileio.o): New rule.
11944
119452015-03-09  Pedro Alves  <palves@redhat.com>
11946
11947	* tracepoint.c (gdb_agent_helper_thread): Cast '&sockaddr' to
11948	'struct sockaddr' pointer in 'accept' call.
11949
119502015-03-09  Pedro Alves  <palves@redhat.com>
11951
11952	Revert:
11953	2015-03-07  Pedro Alves  <palves@redhat.com>
11954	* gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
11955	or <winsock2.h> here.  Instead include "gdb_socket.h".
11956	(remote_open): Use union gdb_sockaddr_u.
11957	* remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
11958	or <winsock2.h> here.  Instead include "gdb_socket.h".
11959	(handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
11960	* tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
11961	or <sys/un.h>.
11962	(init_named_socket, gdb_agent_helper_thread): Use union
11963	gdb_sockaddr_u.
11964
119652015-03-07  Pedro Alves  <palves@redhat.com>
11966
11967	* configure.ac (build_warnings): Move
11968	-Wdeclaration-after-statement to the C-specific set.
11969	* configure: Regenerate.
11970
119712015-03-07  Pedro Alves  <palves@redhat.com>
11972
11973	* gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
11974	or <winsock2.h> here.  Instead include "gdb_socket.h".
11975	(remote_open): Use union gdb_sockaddr_u.
11976	* remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
11977	or <winsock2.h> here.  Instead include "gdb_socket.h".
11978	(handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
11979	* tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
11980	or <sys/un.h>.
11981	(init_named_socket, gdb_agent_helper_thread): Use union
11982	gdb_sockaddr_u.
11983
119842015-03-07  Pedro Alves  <palves@redhat.com>
11985
11986	Adjust all callers of TRY_CATCH to use TRY/CATCH/END_CATCH
11987	instead.
11988
119892015-03-06  Yao Qi  <yao.qi@linaro.org>
11990
11991	* linux-aarch64-low.c (aarch64_insert_point): Use
11992	show_debug_regs as a boolean.
11993	(aarch64_remove_point): Likewise.
11994
119952015-03-05  Pedro Alves  <palves@redhat.com>
11996
11997	* lynx-low.c (lynx_target_ops): Install NULL hooks for
11998	stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
11999	stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint.
12000	* nto-low.c (nto_target_ops): Likewise.
12001	* spu-low.c (spu_target_ops): Likewise.
12002	* win32-low.c (win32_target_ops): Likewise.
12003
120042015-03-04  Pedro Alves  <palves@redhat.com>
12005
12006	* linux-low.c (check_stopped_by_breakpoint) [USE_SIGTRAP_SIGINFO]:
12007	Decide whether a breakpoint triggered based on the SIGTRAP's
12008	siginfo.si_code.
12009	(thread_still_has_status_pending_p) [USE_SIGTRAP_SIGINFO]: Don't check whether a
12010	breakpoint is inserted if relying on SIGTRAP's siginfo.si_code.
12011	(linux_low_filter_event): Check for breakpoints before checking
12012	watchpoints.
12013	(linux_wait_1): Don't re-increment the PC if relying on SIGTRAP's
12014	siginfo.si_code.
12015	(linux_stopped_by_sw_breakpoint)
12016	(linux_supports_stopped_by_sw_breakpoint)
12017	(linux_stopped_by_hw_breakpoint)
12018	(linux_supports_stopped_by_hw_breakpoint): New functions.
12019	(linux_target_ops): Install new target methods.
12020
120212015-03-04  Pedro Alves  <palves@redhat.com>
12022
12023	* remote-utils.c (prepare_resume_reply): Report swbreak/hbreak.
12024	* server.c (swbreak_feature, hwbreak_feature): New globals.
12025	(handle_query) <qSupported>: Handle "swbreak+" and "hwbreak+".
12026	(captured_main): Clear swbreak_feature and hwbreak_feature.
12027	* server.h (swbreak_feature, hwbreak_feature): Declare.
12028	* target.h (struct target_ops) <stopped_by_sw_breakpoint,
12029	supports_stopped_by_sw_breakpoint, stopped_by_hw_breakpoint,
12030	supports_stopped_by_hw_breakpoint>: New fields.
12031	(target_supports_stopped_by_sw_breakpoint)
12032	(target_stopped_by_sw_breakpoint)
12033	(target_supports_stopped_by_hw_breakpoint)
12034	(target_stopped_by_hw_breakpoint): Declare.
12035
120362015-03-04  Pedro Alves  <palves@redhat.com>
12037
12038	enum lwp_stop_reason -> enum target_stop_reason
12039	* linux-low.c (check_stopped_by_breakpoint): Adjust.
12040	(thread_still_has_status_pending_p, check_stopped_by_watchpoint)
12041	(linux_wait_1, stuck_in_jump_pad_callback)
12042	(move_out_of_jump_pad_callback, linux_resume_one_lwp)
12043	(linux_stopped_by_watchpoint):
12044	* linux-low.h (enum lwp_stop_reason): Delete.
12045	(struct lwp_info) <stop_reason>: Now an enum target_stop_reason.
12046	* linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
12047
120482015-03-04  Yao Qi  <yao.qi@linaro.org>
12049
12050	* Makefile.in (SFILES): Add linux-aarch64-low.c.
12051
120522015-03-03  Gary Benson  <gbenson@redhat.com>
12053
12054	* hostio.c (handle_vFile): Fix prefix lengths.
12055
120562015-03-03  Markus Metzger  <markus.t.metzger@intel.com>
12057
12058	* linux-low.c (linux_low_enable_btrace): Do not overwrite non-zero
12059	ptr_bits.
12060
120612015-03-02  Andreas Arnez  <arnez@linux.vnet.ibm.com>
12062
12063	* Makefile.in (s390-vx-linux64.c, s390-tevx-linux64.c)
12064	(s390x-vx-linux64.c, s390x-tevx-linux64.c): New rules.
12065	(clean): Add "rm -f" for above C files.
12066	* configure.srv (srv_regobj): Add s390-vx-linux64.o,
12067	s390-tevx-linux64.o, s390x-vx-linux64.o, and s390x-tevx-linux64.o.
12068	(srv_xmlfiles): Add s390-vx-linux64.xml, s390-tevx-linux64.xml,
12069	s390x-vx-linux64.xml, s390x-tevx-linux64.xml, and s390-vx.xml.
12070	* linux-s390-low.c (HWCAP_S390_VX): New macro.
12071	(init_registers_s390_vx_linux64, init_registers_s390_tevx_linux64)
12072	(init_registers_s390x_vx_linux64)
12073	(init_registers_s390x_tevx_linux64)
12074	(tdesc_s390_vx_linux64, tdesc_s390_tevx_linux64)
12075	(tdesc_s390x_vx_linux64, tdesc_s390x_tevx_linux64): New extern
12076	declarations.
12077	(s390_fill_vxrs_low, s390_store_vxrs_low, s390_fill_vxrs_high)
12078	(s390_store_vxrs_high): New functions.
12079	(s390_regsets): Add entries for NT_S390_VXRS_LOW and
12080	NT_S390_VXRS_HIGH.
12081	(s390_arch_setup): Add logic for selecting one of the new target
12082	descriptions.  Activate the new vector regsets if applicable.
12083	(initialize_low_arch): Also invoke init_registers_s390_vx_linux64,
12084	init_registers_s390_tevx_linux64, init_registers_s390x_vx_linux64,
12085	and init_registers_s390x_tevx_linux64.
12086
120872015-03-01  Pedro Alves  <palves@redhat.com>
12088
12089	* linux-i386-ipa.c (gdb_agent_get_raw_reg): Constify 'raw_regs'
12090	parameter.
12091
120922015-02-27  Pedro Alves  <palves@redhat.com>
12093
12094	* linux-x86-low.c (u_debugreg_offset): New function.
12095	(x86_linux_dr_get, x86_linux_dr_set): Use it.
12096
120972015-02-27  Pedro Alves  <palves@redhat.com>
12098
12099	* gdb_proc_service.h: Wrap with EXTERN_C_PUSH/EXTERN_C_POP.
12100	[!HAVE_PROC_SERVICE_H] (struct ps_prochandle): Forward declare.
12101	[!HAVE_PROC_SERVICE_H] (ps_pdread, ps_pdwrite, ps_ptread)
12102	ps_ptwrite, ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
12103	(ps_lsetfpregs, ps_getpid)
12104	(ps_get_thread_area, ps_pglobal_lookup, ps_pstop, ps_pcontinue)
12105	(ps_lstop, ps_lcontinue, ps_lgetxregsize, ps_lgetxregs)
12106	(ps_lsetxregs, ps_plog): Declare.
12107
121082015-02-27  Pedro Alves  <palves@redhat.com>
12109
12110	* linux-amd64-ipa.c (gdb_agent_get_raw_reg): Use
12111	IP_AGENT_EXPORT_FUNC.
12112	* linux-i386-ipa.c (gdb_agent_get_raw_reg): Use
12113	IP_AGENT_EXPORT_FUNC.
12114	* tracepoint.c (ATTR_USED, ATTR_NOINLINE, ATTR_CONSTRUCTOR)
12115	(IP_AGENT_EXPORT): Delete.
12116	(gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
12117	(gdb_trampoline_buffer, gdb_trampoline_buffer_end)
12118	(gdb_trampoline_buffer_error, collecting, gdb_collect)
12119	(stop_tracing, flush_trace_buffer, about_to_request_buffer_space)
12120	(trace_buffer_is_full, stopping_tracepoint, expr_eval_result)
12121	(error_tracepoint, tracepoints, tracing, trace_buffer_ctrl)
12122	(trace_buffer_ctrl_curr, trace_buffer_lo, trace_buffer_hi)
12123	(traceframe_read_count, traceframe_write_count)
12124	(traceframes_created, trace_state_variables, get_raw_reg)
12125	(get_trace_state_variable_value, set_trace_state_variable_value)
12126	(ust_loaded, helper_thread_id, cmd_buf): Use
12127	IPA_SYM_EXPORTED_NAME.
12128	(stop_tracing, flush_trace_buffer): Use IP_AGENT_EXPORT_FUNC.
12129	(tracepoints) Use IP_AGENT_EXPORT_VAR.
12130	(stopping_tracepoint, trace_buffer_is_full, expr_eval_result): Use
12131	IP_AGENT_EXPORT_VAR and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
12132	(last_tracepoint): Move into !IN_PROCESS_AGENT block.
12133	(error_tracepoint): Use IP_AGENT_EXPORT_VAR and wrap in
12134	EXTERN_C_PUSH/EXTERN_C_POP.
12135	(trace_state_variables): Use IP_AGENT_EXPORT_VAR.
12136	(trace_buffer_lo, trace_buffer_hi): Use IP_AGENT_EXPORT_VAR and
12137	wrap in EXTERN_C_PUSH/EXTERN_C_POP.
12138	(trace_buffer_ctrl, trace_buffer_ctrl_curr)
12139	(traceframe_write_count, traceframe_read_count)
12140	(traceframes_created, tracing): Use IP_AGENT_EXPORT_VAR.
12141	(about_to_request_buffer_space, get_trace_state_variable_value)
12142	(set_trace_state_variable_value): Use IP_AGENT_EXPORT_FUNC.
12143	(collecting): Use IP_AGENT_EXPORT_VAR and wrap in
12144	EXTERN_C_PUSH/EXTERN_C_POP.
12145	(gdb_collect): Use IP_AGENT_EXPORT_FUNC.
12146	(ust_loaded, cmd_buf): Use IP_AGENT_EXPORT_VAR.
12147	(helper_thread_id, gdb_agent_capability): Use IP_AGENT_EXPORT_VAR
12148	and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
12149	(gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
12150	(gdb_trampoline_buffer, gdb_trampoline_buffer_end)
12151	(gdb_trampoline_buffer_error): Use IP_AGENT_EXPORT_VAR.
12152	* tracepoint.h (ATTR_USED, ATTR_NOINLINE, EXPORTED_SYMBOL):
12153	Define.
12154	(IP_AGENT_EXPORT_FUNC, IP_AGENT_EXPORT_VAR)
12155	(IP_AGENT_EXPORT_VAR_DECL): Define.
12156	(tracing): Declare.
12157	(gdb_agent_get_raw_reg): Declare.
12158
121592015-02-27  Tom Tromey  <tromey@redhat.com>
12160	    Pedro Alves  <palves@redhat.com>
12161
12162	Rename symbols whose names are reserved C++ keywords throughout.
12163
121642015-02-27  Pedro Alves  <palves@redhat.com>
12165
12166	* Makefile.in (COMPILER): New, get it from autoconf.
12167	(CXX): Get from autoconf instead.
12168	(COMPILE.pre): Use COMPILER.
12169	(CC-LD): Rename to ...
12170	(CC_LD): ... this.  Use COMPILER.
12171	(gdbserver$(EXEEXT), gdbreplay$(EXEEXT), $(IPA_LIB)): Adjust.
12172	(CXX_FOR_TARGET): Default to g++ instead of gcc.
12173	* acinclude.m4: Include build-with-cxx.m4.
12174	* configure.ac: Call AC_PROG_CXX and GDB_AC_BUILD_WITH_CXX.
12175	Disable -Werror by default if building in C++ mode.
12176	(build_warnings): Add -Wno-sign-compare, -Wno-write-strings and
12177	-Wno-narrowing in C++ mode. Run supported-warning-flags tests with
12178	the C++ compiler.  Save/restore CXXFLAGS too.
12179	* configure: Regenerate.
12180
121812015-02-27  Pedro Alves  <palves@redhat.com>
12182
12183	* acinclude.m4: Include libiberty.m4.
12184	* configure.ac: Call libiberty_INIT.
12185	* config.in, configure: Regenerate.
12186
121872015-02-26  Pedro Alves  <palves@redhat.com>
12188
12189	* linux-low.c (linux_wait_1): When incrementing the PC past a
12190	program breakpoint always use the_low_target.breakpoint_len as
12191	increment, rather than the maximum between that and
12192	the_low_target.decr_pc_after_break.
12193
121942015-02-23  Pedro Alves  <palves@redhat.com>
12195
12196	* linux-low.c (check_stopped_by_breakpoint): Don't check if the
12197	thread was doing a step-over; always adjust the PC if
12198	we stepped over a permanent breakpoint.
12199	(linux_wait_1): If we stepped over breakpoint that was on top of a
12200	permanent breakpoint, manually advance the PC past it.
12201
122022015-02-23  Pedro Alves  <palves@redhat.com>
12203
12204	* linux-x86-low.c (REGSIZE): Define in both 32-bit and 64-bit
12205	modes.
12206	(x86_fill_gregset, x86_store_gregset): Use it when handling
12207	$orig_eax.
12208
122092015-02-20  Pedro Alves  <palves@redhat.com>
12210
12211	* thread-db.c: Include "nat/linux-procfs.h".
12212	(thread_db_init): Skip listing new threads if the kernel supports
12213	PTRACE_EVENT_CLONE and /proc/PID/task/ is accessible.
12214
122152015-02-20  Pedro Alves  <palves@redhat.com>
12216
12217	* linux-low.c (status_pending_p_callback): Use ptid_match.
12218
122192015-02-19  Antoine Tremblay  <antoine.tremblay@ericsson.com>
12220
12221	PR breakpoints/16812
12222	* linux-low.c (wstatus_maybe_breakpoint): Remove.
12223	(linux_low_filter_event): Update wstatus_maybe_breakpoint name.
12224	(linux_wait_1): Report SIGTRAP,SIGILL,SIGSEGV.
12225
122262015-02-10  Antoine Tremblay <antoine.tremblay@ericsson.com>
12227
12228	PR breakpoints/15956
12229	* tracepoint.c (cmd_qtinit): Add check for current_thread.
12230
122312015-02-09  Markus Metzger  <markus.t.metzger@intel.com>
12232
12233	* linux-low.c (linux_low_btrace_conf): Print size.
12234	* server.c (handle_btrace_conf_general_set): New.
12235	(hanle_general_set): Call handle_btrace_conf_general_set.
12236	(handle_query): Report Qbtrace-conf:bts:size as supported.
12237
122382015-02-09  Markus Metzger  <markus.t.metzger@intel.com>
12239
12240	* linux-low.c (linux_low_enable_btrace): Update parameters.
12241	(linux_low_btrace_conf): New.
12242	(linux_target_ops)<to_btrace_conf>: Initialize.
12243	* server.c (current_btrace_conf): New.
12244	(handle_btrace_enable): Rename to ...
12245	(handle_btrace_enable_bts): ... this.  Pass &current_btrace_conf
12246	to target_enable_btrace.  Update comment.  Update users.
12247	(handle_qxfer_btrace_conf): New.
12248	(qxfer_packets): Add btrace-conf entry.
12249	(handle_query): Report qXfer:btrace-conf:read as supported packet.
12250	* target.h (target_ops)<enable_btrace>: Update parameters and comment.
12251	(target_ops)<read_btrace_conf>: New.
12252	(target_enable_btrace): Update parameters.
12253	(target_read_btrace_conf): New.
12254
122552015-02-09  Markus Metzger  <markus.t.metzger@intel.com>
12256
12257	* server.c (handle_btrace_general_set): Remove call to
12258	target_supports_btrace.
12259	(supported_btrace_packets): New.
12260	(handle_query): Call supported_btrace_packets.
12261	* target.h: include btrace-common.h.
12262	(btrace_target_info): Removed.
12263	(supports_btrace, target_supports_btrace): Update parameters.
12264
122652015-02-09  Markus Metzger  <markus.t.metzger@intel.com>
12266
12267	* Makefile.in (SFILES): Add common/btrace-common.c.
12268	(OBS): Add common/btrace-common.o.
12269	(btrace-common.o): Add build rules.
12270	* linux-low: Include btrace-common.h.
12271	(linux_low_read_btrace): Use struct btrace_data.  Call
12272	btrace_data_init and btrace_data_fini.
12273
122742015-02-06  Pedro Alves  <palves@redhat.com>
12275
12276	* thread-db.c (find_new_threads_callback): Add debug output.
12277
122782015-02-04  Pedro Alves  <palves@redhat.com>
12279
12280	* linux-low.c (handle_extended_wait): Don't resume LWPs here.
12281	(resume_stopped_resumed_lwps): New function.
12282	(linux_wait_for_event_filtered): Use it.
12283
122842015-01-15  Sergio Durigan Junior  <sergiodj@redhat.com>
12285
12286	* Makefile.in (SFILES): Add linux-personality.c.
12287	(linux-personality.o): New rule.
12288	* configure.srv (srv_linux_obj): Add linux-personality.o to the
12289	list of objects to be built.
12290	* linux-low.c: Include nat/linux-personality.h.
12291	(linux_create_inferior): Remove code to disable address space
12292	randomization (moved to ../nat/linux-personality.c).  Create
12293	cleanup to disable address space randomization.
12294
122952015-01-15  Sergio Durigan Junior  <sergiodj@redhat.com>
12296
12297	* Makefile.in (posix-strerror.o): New rule.
12298	(mingw-strerror.o): Likewise.
12299	* configure: Regenerated.
12300	* configure.ac: Source file ../common/common.host.  Initialize new
12301	variable srv_host_obs.  Add srv_host_obs to GDBSERVER_DEPFILES.
12302
123032015-01-14  Yao Qi  <yao@codesourcery.com>
12304
12305	* Makefile.in (SFILES): Add nat/ppc-linux.c.
12306	(ppc-linux.o): New rule.
12307	* configure.srv (powerpc*-*-linux*): Add ppc-linux.o.
12308	* configure.ac: AC_CHECK_FUNCS(getauxval).
12309	* config.in: Re-generated.
12310	* configure: Re-generated.
12311	* linux-ppc-low.c (ppc_arch_setup) [__powerpc64__]: Call
12312	ppc64_64bit_inferior_p
12313
123142015-01-14  Yao Qi  <yao@codesourcery.com>
12315
12316	* linux-ppc-low.c: Include "nat/ppc-linux.h".
12317	 (PPC_FEATURE_HAS_VSX): Move to nat/ppc-linux.h.
12318	(PPC_FEATURE_HAS_ALTIVEC,  PPC_FEATURE_HAS_SPE): Likewise.
12319	(PT_ORIG_R3, PT_TRAP): Likewise.
12320	(PTRACE_GETVSXREGS, PTRACE_SETVSXREGS): Likewise.
12321	(PTRACE_GETVRREGS, PTRACE_SETVRREGS): Likewise.
12322	(PTRACE_GETEVRREGS, PTRACE_SETEVRREGS): Likewise.
12323
123242015-01-10  Joel Brobecker  <brobecker@adacore.com>
12325
12326	* i387-fp.c (i387_cache_to_xsave): In look over
12327	num_avx512_zmmh_high_registers, replace use of struct i387_xsave
12328	zmmh_low_space field by use of zmmh_high_space.
12329
123302015-01-09  Pedro Alves  <palves@redhat.com>
12331
12332	* linux-low.c (step_over_bkpt): Move higher up in the file.
12333	(handle_extended_wait): Don't store the stop_pc here.
12334	(get_stop_pc): Adjust comments and rename to ...
12335	(check_stopped_by_breakpoint): ... this.  Record whether the LWP
12336	stopped for a software breakpoint or hardware breakpoint.
12337	(thread_still_has_status_pending_p): New function.
12338	(status_pending_p_callback): Use
12339	thread_still_has_status_pending_p.  If the event is no longer
12340	interesting, resume the LWP.
12341	(handle_tracepoints): Add assert.
12342	(maybe_move_out_of_jump_pad): Remove cancel_breakpoints call.
12343	(wstatus_maybe_breakpoint): New function.
12344	(cancel_breakpoint): Delete function.
12345	(check_stopped_by_watchpoint): New function, factored out from
12346	linux_low_filter_event.
12347	(lp_status_maybe_breakpoint): Delete function.
12348	(linux_low_filter_event): Remove filter_ptid argument.
12349	Leave thread group exits pending here.	Store the LWP's stop PC.
12350	Always leave events pending.
12351	(linux_wait_for_event_filtered): Pull all events out of the
12352	kernel, and leave them all pending.
12353	(count_events_callback, select_event_lwp_callback): Consider all
12354	events.
12355	(cancel_breakpoints_callback, linux_cancel_breakpoints): Delete.
12356	(select_event_lwp): Only give preference to the stepping LWP in
12357	all-stop mode.	Adjust comments.
12358	(ignore_event): New function.
12359	(linux_wait_1): Delete 'retry' label.  Use ignore_event.  Remove
12360	references to cancel_breakpoints.  Adjust to renames.  Also give
12361	equal priority to all LWPs that have had events in non-stop mode.
12362	If reporting a software breakpoint event, unadjust the LWP's PC.
12363	(linux_wait): If linux_wait_1 returned an ignored event, retry.
12364	(stuck_in_jump_pad_callback, move_out_of_jump_pad_callback):
12365	Adjust.
12366	(linux_resume_one_lwp): Store the LWP's PC.  Adjust.
12367	(resume_status_pending_p): Use thread_still_has_status_pending_p.
12368	(linux_stopped_by_watchpoint): Adjust.
12369	(linux_target_ops): Remove reference to linux_cancel_breakpoints.
12370	* linux-low.h (enum lwp_stop_reason): New.
12371	(struct lwp_info) <stop_pc>: Adjust comment.
12372	<stopped_by_watchpoint>: Delete field.
12373	<stop_reason>: New field.
12374	* linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
12375	* mem-break.c (software_breakpoint_inserted_here)
12376	(hardware_breakpoint_inserted_here): New function.
12377	* mem-break.h (software_breakpoint_inserted_here)
12378	(hardware_breakpoint_inserted_here): Declare.
12379	* target.h (struct target_ops) <cancel_breakpoints>: Remove field.
12380	(cancel_breakpoints): Delete.
12381	* tracepoint.c (clear_installed_tracepoints, stop_tracing)
12382	(upload_fast_traceframes): Remove references to
12383	cancel_breakpoints.
12384
123852015-01-09  Pedro Alves  <palves@redhat.com>
12386
12387	* thread-db.c (find_new_threads_callback): Ignore thread if the
12388	kernel thread ID is -1.
12389
123902015-01-09  Pedro Alves  <palves@redhat.com>
12391
12392	* linux-low.c (linux_attach_fail_reason_string): Move to
12393	nat/linux-ptrace.c, and rename.
12394	(linux_attach_lwp): Update comment.
12395	(attach_proc_task_lwp_callback): New function.
12396	(linux_attach): Adjust to rename and use
12397	linux_proc_attach_tgid_threads.
12398	(linux_attach_fail_reason_string): Delete declaration.
12399
124002015-01-01  Joel Brobecker  <brobecker@adacore.com>
12401
12402	* gdbreplay.c (gdbreplay_version): Update copyright year to 2015.
12403	* server.c (gdbserver_version): Likewise.
12404
124052014-12-29  Sergio Durigan Junior  <sergiodj@redhat.com>
12406
12407	* remote-utils.c: Include ctype.h.
12408	(input_interrupt): Explicitly handle the case when the char
12409	received is the NUL byte.  Improve the printing of non-ASCII
12410	characters.
12411
124122014-12-16  Joel Brobecker  <brobecker@adacore.com>
12413
12414	* linux-low.c (linux_low_filter_event): Update call to
12415	linux_enable_event_reporting following the addition of
12416	a new parameter to that function.
12417
124182014-12-16  Catalin Udma  <catalin.udma@freescale.com>
12419
12420	PR server/17457
12421	* linux-aarch64-low.c (AARCH64_FPSR_REGNO): New define.
12422	(AARCH64_FPCR_REGNO): Likewise.
12423	(AARCH64_NUM_REGS): Update to include fpsr/fpcr registers.
12424	(aarch64_fill_fpregset): Add missing fpsr/fpcr registers.
12425	(aarch64_store_fpregset): Likewise.
12426
124272014-12-15  Joel Brobecker  <brobecker@adacore.com>
12428
12429	* lynx-low.c (lynx_resume): Use PTRACE_SINGLESTEP_ONE if N == 1.
12430	Remove FIXME comment about assumption about N.
12431
124322014-12-13  Joel Brobecker  <brobecker@adacore.com>
12433
12434	* configure.ac: If large-file support is disabled in GDBserver,
12435	pass --disable-largefile to ACX_CONFIGURE_DIR call for "gnulib".
12436	* configure: Regenerate.
12437
124382014-12-12  Andreas Arnez  <arnez@linux.vnet.ibm.com>
12439
12440	* linux-low.c (regsets_fetch_inferior_registers): Suppress the
12441	warning upon ENODATA from ptrace.
12442	* linux-s390-low.c (s390_store_tdb): New.
12443	(s390_regsets): Add regset for NT_S390_TDB.
12444
124452014-12-12  Andreas Arnez  <arnez@linux.vnet.ibm.com>
12446
12447	* linux-low.c (regsets_store_inferior_registers): Skip regsets
12448	without a fill_function.
12449	* linux-s390-low.c (s390_fill_last_break): Remove.
12450	(s390_regsets): Set fill_function to NULL for NT_S390_LAST_BREAK.
12451	(s390_arch_setup): Use regset's size instead of fill_function for
12452	loop end condition.
12453
124542014-12-12  Andreas Arnez  <arnez@linux.vnet.ibm.com>
12455
12456	* linux-low.c (regsets_fetch_inferior_registers): Do not invoke
12457	the regset's store function when ptrace returned an error.
12458	* regcache.c (get_thread_regcache): Invalidate register cache
12459	before fetching inferior's registers.
12460
124612014-12-12  Andreas Arnez  <arnez@linux.vnet.ibm.com>
12462
12463	* linux-low.c (regsets_fetch_inferior_registers): Rephrase
12464	while-loop as for-loop.
12465	(regsets_store_inferior_registers): Likewise.
12466
124672014-11-28  Yao Qi  <yao@codesourcery.com>
12468
12469	* configure.ac(AC_CHECK_FUNCS): Remove readlink.
12470	* config.in, configure: Re-generate.
12471	* hostio.c (handle_unlink): Remove code checking HAVE_READLINK
12472	is defined.
12473
124742014-11-21  Yao Qi  <yao@codesourcery.com>
12475
12476	* configure.ac: Don't invoke AC_FUNC_ALLOCA.
12477	(AC_CHECK_HEADERS): Remove malloc.h.
12478	* configure: Re-generated.
12479	* config.in: Re-generated.
12480	* server.h: Don't include alloca.h and malloc.h.
12481	* gdbreplay.c: Don't check HAVE_ALLOCA_H is defined.
12482	Don't include malloc.h.
12483
124842014-11-17  Joel Brobecker  <brobecker@adacore.com>
12485
12486	* lynx-low.c (lynx_write_memory): Put lynx_read_memory and
12487	corresponding ERRNO check in same block.
12488
124892014-11-12  Pedro Alves  <palves@redhat.com>
12490
12491	* server.c (cont_thread): Update comment.
12492	(start_inferior, attach_inferior): No longer clear cont_thread.
12493	(handle_v_cont): No longer set cont_thread.
12494	(captured_main): Clear cont_thread each time a GDB connects.
12495
124962014-11-12  Pedro Alves  <palves@redhat.com>
12497
12498	* linux-low.c (linux_wait_1): Don't force a wait for the Hc
12499	thread, and don't resume all threads if the Hc thread has exited.
12500
125012014-11-12  Pedro Alves  <palves@redhat.com>
12502
12503	* linux-low.c (linux_request_interrupt): Always send a SIGINT to
12504	the process group instead of to a specific LWP.
12505
125062014-10-15  Pedro Alves  <palves@redhat.com>
12507
12508	PR server/17487
12509	* win32-arm-low.c (arm_set_thread_context): Remove current_event
12510	parameter.
12511	(arm_set_thread_context): Delete.
12512	(the_low_target): Adjust.
12513	* win32-i386-low.c (debug_registers_changed)
12514	(debug_registers_used): Delete.
12515	(update_debug_registers_callback): New function.
12516	(x86_dr_low_set_addr, x86_dr_low_set_control): Mark all threads as
12517	needing to update their debug registers.
12518	(win32_get_current_dr): New function.
12519	(x86_dr_low_get_addr, x86_dr_low_get_control)
12520	(x86_dr_low_get_status): Fetch the debug register from the thread
12521	record's context.
12522	(i386_initial_stuff): Adjust.
12523	(i386_get_thread_context): Remove current_event parameter.  Don't
12524	clear debug_registers_changed nor copy DR values to
12525	debug_reg_state.
12526	(i386_set_thread_context): Delete.
12527	(i386_prepare_to_resume): New function.
12528	(i386_thread_added): Mark the thread as needing to update irs
12529	debug registers.
12530	(the_low_target): Remove i386_set_thread_context and install
12531	i386_prepare_to_resume.
12532	* win32-low.c (win32_get_thread_context): Adjust.
12533	(win32_set_thread_context): Use SetThreadContext
12534	directly.
12535	(win32_prepare_to_resume): New function.
12536	(win32_require_context): New function, factored out from ...
12537	(thread_rec): ... this.
12538	(continue_one_thread): Call win32_prepare_to_resume on each thread
12539	we're about to continue.
12540	(win32_resume): Call win32_prepare_to_resume on the event thread.
12541	* win32-low.h (struct win32_thread_info)
12542	<debug_registers_changed>: New field.
12543	(struct win32_target_ops): Change prototype of set_thread_context,
12544	delete set_thread_context and add prepare_to_resume.
12545	(win32_require_context): New declaration.
12546
125472014-10-08  Gary Benson  <gbenson@redhat.com>
12548
12549	* server.h: Do not include common-exceptions.h.
12550
125512014-10-08  Gary Benson  <gbenson@redhat.com>
12552
12553	* server.h: Do not include cleanups.h.
12554
125552014-09-30  James Hogan  <james.hogan@imgtec.com>
12556
12557	* Makefile.in (clean): Add rm -f commands for mips-dsp-linux.c and
12558	mips64-dsp-linux.c.
12559
125602014-09-23  Yao Qi  <yao@codesourcery.com>
12561
12562	* linux-low.c (lp_status_maybe_breakpoint): New function.
12563	(linux_low_filter_event): Call lp_status_maybe_breakpoint.
12564	(count_events_callback): Likewise.
12565	(select_event_lwp_callback): Likewise.
12566	(cancel_breakpoints_callback): Likewise.
12567
125682014-09-19  Don Breazeal  <donb@codesourcery.com>
12569
12570	* linux-low.c (handle_extended_wait): Call
12571	linux_ptrace_get_extended_event.
12572	(get_stop_pc, get_detach_signal, linux_low_filter_event): Call
12573	linux_is_extended_waitstatus.
12574
125752014-09-16  Joel Brobecker  <brobecker@adacore.com>
12576
12577	* Makefile.in (CPPFLAGS): Define.
12578	(INTERNAL_CFLAGS_BASE): Add ${CPPFLAGS}.
12579	(IPAGENT_CFLAGS): Remove ${CPPFLAGS}.
12580
125812014-09-16  Gary Benson  <gbenson@redhat.com>
12582
12583	* inferiors.h (current_inferior): Renamed as...
12584	(current_thread): New variable.  All uses updated.
12585	* linux-low.c (get_pc): Renamed saved_inferior as saved_thread.
12586	(maybe_move_out_of_jump_pad): Likewise.
12587	(cancel_breakpoint): Likewise.
12588	(linux_low_filter_event): Likewise.
12589	(wait_for_sigstop): Likewise.
12590	(linux_resume_one_lwp): Likewise.
12591	(need_step_over_p): Likewise.
12592	(start_step_over): Likewise.
12593	(linux_stabilize_threads): Renamed save_inferior as saved_thread.
12594	* linux-x86-low.c (x86_linux_update_xmltarget): Likewise.
12595	* proc-service.c (ps_lgetregs): Renamed reg_inferior as reg_thread
12596	and save_inferior as saved_thread.
12597	* regcache.c (get_thread_regcache): Renamed saved_inferior as
12598	saved_thread.
12599	(regcache_invalidate_thread): Likewise.
12600	* remote-utils.c (prepare_resume_reply): Likewise.
12601	* thread-db.c (thread_db_get_tls_address): Likewise.
12602	(disable_thread_event_reporting): Likewise.
12603	(remove_thread_event_breakpoints): Likewise.
12604	* tracepoint.c (gdb_agent_about_to_close): Renamed save_inferior
12605	as saved_thread.
12606	* target.h (set_desired_inferior): Renamed as...
12607	(set_desired_thread): New declaration.  All uses updated.
12608	* server.c (myresume): Updated comment to reference thread instead
12609	of inferior.
12610	(handle_serial_event): Likewise.
12611	(handle_target_event): Likewise.
12612
126132014-09-12  Tom Tromey  <tromey@redhat.com>
12614	    Gary Benson  <gbenson@redhat.com>
12615
12616	* regcache.h: Include common-regcache.h.
12617	(regcache_read_pc): Don't declare.
12618	* regcache.c (get_thread_regcache_for_ptid): New function.
12619
126202014-09-11  Tom Tromey  <tromey@redhat.com>
12621	    Gary Benson  <gbenson@redhat.com>
12622
12623	* symbol.c: New file.
12624	* Makefile.in (SFILES): Add symbol.c.
12625	(OBS): Add symbol.o.
12626
126272014-09-11  Gary Benson  <gbenson@redhat.com>
12628
12629	* target.c (target_stop_ptid, target_continue_ptid): New
12630	functions.
12631
126322014-09-11  Tom Tromey  <tromey@redhat.com>
12633	    Gary Benson  <gbenson@redhat.com>
12634
12635	* target.h: Include target/target.h.
12636	* target.c (target_read_memory, target_read_uint32)
12637	(target_write_memory): New functions.
12638
126392014-09-11  Gary Benson  <gbenson@redhat.com>
12640
12641	* server.h (debug_hw_points): Don't declare.
12642	* server.c (debug_hw_points): Don't define.  Replace all uses
12643	with show_debug_regs.
12644	* linux-aarch64-low.c (debug_hw_points): Don't define.  Replace
12645	all uses with show_debug_regs.
12646
126472014-09-08  Edjunior Barbosa Machado  <emachado@linux.vnet.ibm.com>
12648
12649	* linux-ppc-low.c (ppc_collect_ptrace_register): Adjust routine to take
12650	endianness into account.
12651	(ppc_supply_ptrace_register): Likewise.
12652
126532014-09-03  James Hogan  <james.hogan@imgtec.com>
12654
12655	* linux-mips-low.c (mips_read_description): Reset errno to 0 prior
12656	to reading DSP_CONTROL with PTRACE_PEEKUSER ptrace call.
12657
126582014-09-03  Gary Benson  <gbenson@redhat.com>
12659
12660	* linux-x86-low.c (x86_linux_prepare_to_resume): Use
12661	ALL_DEBUG_ADDRESS_REGISTERS.
12662
126632014-09-02  Gary Benson  <gbenson@redhat.com>
12664
12665	* i386-low.h: Renamed as...
12666	* x86-low.h: New file.  All type, function and variable name
12667	prefixes changed from "i386_" to "x86_".  All references updated.
12668	* i386-low.c: Renamed as...
12669	* x86-low.c: New file.  All type, function and variable name
12670	prefixes changed from "i386_" to "x86_".  All references updated.
12671
126722014-09-02  Gary Benson  <gbenson@redhat.com>
12673
12674	* linux-x86-low.c (x86_linux_new_process): Use XCNEW.
12675	(x86_linux_new_thread): Likewise.
12676
126772014-08-29  Gary Benson  <gbenson@redhat.com>
12678
12679	* server.h (setjmp.h): Do not include.
12680	(toplevel): Do not declare.
12681	(common-exceptions.h): Include.
12682	(cleanups.h): Likewise.
12683	* server.c (toplevel): Do not define.
12684	(exit_code): New static global.
12685	(detach_or_kill_for_exit_cleanup): New function.
12686	(main): New function.  Original main renamed to...
12687	(captured_main): New function.
12688	* utils.c (verror) [!IN_PROCESS_AGENT]: Use throw_verror.
12689
126902014-08-29  Gary Benson  <gbenson@redhat.com>
12691
12692	* Makefile.in (SFILES): Add common/common-exceptions.c.
12693	(OBS): Add common-exceptions.o.
12694	(common-exceptions.o): New rule.
12695	* utils.c (prepare_to_throw_exception): New function.
12696
126972014-08-29  Gary Benson  <gbenson@redhat.com>
12698
12699	* config.in: Regenerate.
12700	* configure: Likewise.
12701
127022014-08-29  Gary Benson  <gbenson@redhat.com>
12703
12704	* Makefile.in (SFILES): Add common/cleanups.c.
12705	(OBS): cleanups.o.
12706	(cleanups.o): New rule.
12707
127082014-08-29  Gary Benson  <gbenson@redhat.com>
12709
12710	* utils.c (internal_vwarning): New function.
12711
127122014-08-28  Gary Benson  <gbenson@redhat.com>
12713
12714	* utils.h (fatal): Remove declaration.
12715	* utils.c (fatal): Remove function.
12716
127172014-08-28  Gary Benson  <gbenson@redhat.com>
12718
12719	* tracepoint.c (gdb_agent_init): Replace fatal with
12720	perror_with_name.
12721	(initialize_tracepoint): Likewise.
12722
127232014-08-28  Gary Benson  <gbenson@redhat.com>
12724
12725	* remote-utils.c (remote_prepare): Replace fatal with error.
12726
127272014-08-28  Gary Benson  <gbenson@redhat.com>
12728
12729	* linux-low.c (linux_async): Replace fatal with warning.
12730	Tidy up and return.
12731	(linux_start_non_stop): Return -1 if linux_async failed.
12732
127332014-08-28  Gary Benson  <gbenson@redhat.com>
12734
12735	* linux-x86-low.c (i386_dr_low_set_addr): Replace check with
12736	gdb_assert.
12737	(i386_dr_low_get_addr): Remove vague comment.
12738	* win32-i386-low.c (i386_dr_low_set_addr): Replace check with
12739	gdb_assert.
12740
127412014-08-28  Gary Benson  <gbenson@redhat.com>
12742
12743	* inferiors.c (get_thread_process): Replace check with gdb_assert.
12744	* linux-low.c (linux_wait_for_event_filtered): Replace fatal with
12745	internal_error.
12746	(linux_resume_one_lwp): Likewise.
12747	* linux-x86-low.c (x86_siginfo_fixup): Replace checks with
12748	gdb_assert.
12749	* mem-break.c (raw_bkpt_type_to_target_hw_bp_type): Replace fatal
12750	with internal_error.
12751	* regcache.c (get_thread_regcache): Replace check with gdb_assert.
12752	(init_register_cache): Replace fatal with gdb_assert_not_reached.
12753	(find_register_by_name): Replace fatal with internal_error.
12754	(find_regno): Likewise.
12755	* tdesc.c (init_target_desc): Replace check with gdb_assert.
12756	* thread-db.c (thread_db_create_event): Likewise.
12757	(thread_db_load_search): Likewise.
12758	(try_thread_db_load_1): Likewise.
12759	* tracepoint.c (get_jump_space_head): Replace fatal with
12760	internal_error.
12761	(claim_trampoline_space): Likewise.
12762	(have_fast_tracepoint_trampoline_buffer): Likewise.
12763	(cmd_qtstart): Likewise.
12764	(stop_tracing): Likewise.
12765	(fast_tracepoint_collecting): Likewise.
12766	(target_malloc): Likewise.
12767	(download_tracepoint): Likewise.
12768	(download_trace_state_variables): Replace check with gdb_assert.
12769	(upload_fast_traceframes): Replace fatal with internal_error.
12770
127712014-08-19  Tom Tromey  <tromey@redhat.com>
12772	    Gary Benson  <gbenson@redhat.com>
12773
12774	* Makefile.in (SFILES): Add common/common-debug.c.
12775	(OBS): Add common-debug.o.
12776	(common-debug.o): New rule.
12777	* debug.h (debug_printf): Don't declare.
12778	* debug.c (debug_printf): Renamed and rewritten as...
12779	(debug_vprintf): New function.
12780
127812014-08-19  Gary Benson  <gbenson@redhat.com>
12782
12783	* utils.h: Do not include print-utils.h.
12784
127852014-08-19  Tom Tromey  <tromey@redhat.com>
12786	    Gary Benson  <gbenson@redhat.com>
12787
12788	* server.h: Add static assertion.
12789	(gdb_byte, CORE_ADDR, LONGEST, ULONGEST): Remove.
12790
127912014-08-19  Tom Tromey  <tromey@redhat.com>
12792	    Gary Benson  <gbenson@redhat.com>
12793
12794	* Makefile.in (SFILES): Add common/errors.c.
12795	(OBS): Add errors.o.
12796	(IPA_OBS): Add errors-ipa.o.
12797	(errors.o): New rule.
12798	(errors-ipa.o): Likewise.
12799	* utils.h (perror_with_name, error, warning): Don't declare.
12800	* utils.c (warning): Renamed and rewritten as...
12801	(vwarning): New function.
12802	(error): Renamed and rewritten as...
12803	(verror): New function.
12804	(internal_error): Renamed and rewritten as...
12805	(internal_verror): New function.
12806
128072014-08-07  Gary Benson  <gbenson@redhat.com>
12808
12809	* configure.ac (AC_CHECK_HEADERS): Remove errno.h.
12810	* configure: Regenerate.
12811	* config.in: Likewise.
12812	* server.h: Do not include errno.h.
12813	* event-loop.c: Likewise.
12814	* hostio-errno.c: Likewise.
12815	* linux-low.c: Likewise.
12816	* remote-utils.c: Likewise.
12817	* spu-low.c: Likewise.
12818	* utils.c: Likewise.
12819	* gdbreplay.c: Unconditionally include errno.h.
12820
128212014-08-07  Gary Benson  <gbenson@redhat.com>
12822
12823	* server.h: Do not include string.h.
12824	* event-loop.c: Likewise.
12825	* linux-low.c: Likewise.
12826	* regcache.c: Likewise.
12827	* remote-utils.c: Likewise.
12828	* spu-low.c: Likewise.
12829	* utils.c: Likewise.
12830
128312014-08-07  Gary Benson  <gbenson@redhat.com>
12832
12833	* server.h: Do not include gdb_assert.h.
12834
128352014-08-07  Gary Benson  <gbenson@redhat.com>
12836
12837	* server.h: Do not include common-utils.h.
12838
128392014-08-07  Gary Benson  <gbenson@redhat.com>
12840
12841	* server.h: Do not include ptid.h.
12842	* notif.h: Likewise.
12843
128442014-08-07  Gary Benson  <gbenson@redhat.com>
12845
12846	* server.h: Do not include gdb_locale.h.
12847
128482014-08-07  Gary Benson  <gbenson@redhat.com>
12849
12850	* server.h: Do not include gdb/signals.h.
12851	* win32-low.c: Likewise.
12852
128532014-08-07  Gary Benson  <gbenson@redhat.com>
12854
12855	* server.h: Do not include pathmax.h.
12856
128572014-08-07  Gary Benson  <gbenson@redhat.com>
12858
12859	* server.h: Do not include libiberty.h.
12860	* linux-bfin-low.c: Likewise.
12861
128622014-08-07  Gary Benson  <gbenson@redhat.com>
12863
12864	* server.h: Do not include ansidecl.h.
12865
128662014-08-07  Gary Benson  <gbenson@redhat.com>
12867
12868	* linux-x86-low.c: Do not include stddef.h.
12869	* lynx-ppc-low.c: Likewise.
12870	* tracepoint.c: Likewise.
12871
128722014-08-07  Gary Benson  <gbenson@redhat.com>
12873
12874	* server.h: Do not include stdarg.h.
12875	* nto-low.c: Likewise.
12876
128772014-08-07  Gary Benson  <gbenson@redhat.com>
12878
12879	* server.h: Do not include stdlib.h.
12880	* inferiors.c: Likewise.
12881	* linux-low.c: Likewise.
12882	* regcache.c: Likewise.
12883	* spu-low.c: Likewise.
12884	* tracepoint.c: Likewise.
12885	* utils.c: Likewise.
12886
128872014-08-07  Gary Benson  <gbenson@redhat.com>
12888
12889	* server.h: Do not include stdio.h.
12890	* linux-low.c: Likewise.
12891	* remote-utils.c: Likewise.
12892	* spu-low.c: Likewise.
12893	* utils.c: Likewise.
12894	* wincecompat.c: Likewise.
12895
128962014-08-06  Gary Benson  <gbenson@redhat.com>
12897
12898	* regcache.c (init_register_cache): Move conditionals inside if.
12899
129002014-08-06  Gary Benson  <gbenson@redhat.com>
12901
12902	* linux-low.c (linux_supports_non_stop): Use target_is_async_p.
12903
129042014-07-31  Gary Benson  <gbenson@redhat.com>
12905
12906	* ax.h: Do not include server.h.
12907	* gdbthread.h: Likewise.
12908	* lynx-low.h: Likewise.
12909	* notif.h: Likewise.
12910
129112014-07-30  Gary Benson  <gbenson@redhat.com>
12912
12913	* server.h: Include common-defs.h.
12914	Do not include config.h or build-gnulib-gdbserver/config.h.
12915
129162014-07-30  Gary Benson  <gbenson@redhat.com>
12917
12918	* hostio-errno.c: Move server.h to top of includes list.
12919	* inferiors.c: Likewise.
12920	* linux-x86-low.c: Likewise.
12921	* notif.c: Include server.h.
12922
129232014-07-24  Tom Tromey  <tromey@redhat.com>
12924	    Gary Benson  <gbenson@redhat.com>
12925
12926	* server.h (CORE_ADDR): Now unsigned.
12927
129282014-07-16  Pedro Alves  <palves@redhat.com>
12929
12930	* linux-low.c (linux_kill_one_lwp): Use kill_lwp, not kill.
12931
129322014-07-15  Pedro Alves  <palves@redhat.com>
12933
12934	* linux-low.c (linux_kill_one_lwp): Save errno and work with saved
12935	copy.
12936
129372014-07-11  Pedro Alves  <palves@redhat.com>
12938
12939	* linux-low.c (kill_wait_lwp): New function, based on
12940	kill_one_lwp_callback, but use my_waitpid directly.
12941	(kill_one_lwp_callback, linux_kill): Use it.
12942
129432014-06-23  Pedro Alves  <palves@redhat.com>
12944
12945	* linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR_CONTROL
12946	before setting DR0..DR3.
12947
129482014-06-20  Gary Benson  <gbenson@redhat.com>
12949
12950	* configure.ac (AC_REPLACE_FUNCS) <vasprintf, vsnprintf>: Removed.
12951	* configure: Regenerated.
12952	* config.in: Likewise.
12953
129542014-06-20  Gary Benson  <gbenson@redhat.com>
12955
12956	* Makefile.in (SFILES): Update locations for files moved
12957	from common to nat.
12958	(object file files): Reordered.
12959
129602014-06-20  Gary Benson  <gbenson@redhat.com>
12961
12962	* i386-low.h (i386_dr_low_can_set_addr): Removed.
12963	(i386_dr_low_set_addr): Likewise.
12964	(i386_dr_low_get_addr): Likewise.
12965	(i386_dr_low_can_set_control): Likewise.
12966	(i386_dr_low_set_control): Likewise.
12967	(i386_dr_low_get_control): Likewise.
12968	(i386_dr_low_get_status): Likewise.
12969	(i386_get_debug_register_length): Likewise.
12970	* linux-x86-low.c (i386_dr_low_set_addr):
12971	Changed signature.  Made static.
12972	(i386_dr_low_get_addr): Likewise.
12973	(i386_dr_low_set_control): Likewise.
12974	(i386_dr_low_get_control): Likewise.
12975	(i386_dr_low_get_status): Likewise.
12976	(i386_dr_low): New global variable.
12977	* win32-i386-low.c (i386_dr_low_set_addr):
12978	Changed signature.  Made static.
12979	(i386_dr_low_get_addr): Likewise.
12980	(i386_dr_low_set_control): Likewise.
12981	(i386_dr_low_get_control): Likewise.
12982	(i386_dr_low_get_status): Likewise.
12983	(i386_dr_low): New global variable.
12984
129852014-06-20  Marcus Shawcroft  <marcus.shawcroft@arm.com>
12986
12987	* configure.ac: Invoke. AC_CHECK_TOOL(AR, ar).
12988	* Makefile.in (AR, AR_FLAGS): Define.
12989	* configure: Regenerate.
12990
129912014-06-19  Gary Benson  <gbenson@redhat.com>
12992
12993	* Makefile.in (i386-dregs.o): New rule.
12994	* configure.srv: Add i386-dregs.o to all targets using i386-low.o.
12995	* i386-low.c (target.h): Remove include.
12996	(TARGET_HAS_DR_LEN_8): Now in i386-dregs.c.
12997	(DR_CONTROL_SHIFT): Likewise.
12998	(DR_CONTROL_SIZE): Likewise.
12999	(DR_RW_EXECUTE): Likewise.
13000	(DR_RW_WRITE): Likewise.
13001	(DR_RW_READ): Likewise.
13002	(DR_RW_IORW): Likewise.
13003	(DR_LEN_1): Likewise.
13004	(DR_LEN_2): Likewise.
13005	(DR_LEN_4): Likewise.
13006	(DR_LEN_8): Likewise.
13007	(DR_LOCAL_ENABLE_SHIFT): Likewise.
13008	(DR_GLOBAL_ENABLE_SHIFT): Likewise.
13009	(DR_ENABLE_SIZE): Likewise.
13010	(DR_LOCAL_SLOWDOWN): Likewise.
13011	(DR_GLOBAL_SLOWDOWN): Likewise.
13012	(DR_CONTROL_RESERVED): Likewise.
13013	(I386_DR_CONTROL_MASK): Likewise.
13014	(I386_DR_VACANT): Likewise.
13015	(I386_DR_LOCAL_ENABLE): Likewise.
13016	(I386_DR_GLOBAL_ENABLE): Likewise.
13017	(I386_DR_DISABLE): Likewise.
13018	(I386_DR_SET_RW_LEN): Likewise.
13019	(I386_DR_GET_RW_LEN): Likewise.
13020	(I386_DR_WATCH_HIT): Likewise.
13021	(i386_wp_op_t): Likewise.
13022	(i386_show_dr): Likewise.
13023	(i386_length_and_rw_bits): Likewise.
13024	(i386_insert_aligned_watchpoint): Likewise.
13025	(i386_remove_aligned_watchpoint): Likewise.
13026	(i386_handle_nonaligned_watchpoint): Likewise.
13027	i386_update_inferior_debug_regs(): Likewise.
13028	(i386_dr_insert_watchpoint): Likewise.
13029	(i386_dr_remove_watchpoint): Likewise.
13030	(i386_dr_region_ok_for_watchpoint): Likewise.
13031	(i386_dr_stopped_data_address): Likewise.
13032	(i386_dr_stopped_by_watchpoint): Likewise.
13033
130342014-06-19  Gary Benson  <gbenson@redhat.com>
13035
13036	* i386-low.c (i386_dr_show): Renamed to
13037	i386_show_dr and made static.  All uses updated.
13038	(i386_dr_length_and_rw_bits): Renamed to
13039	i386_length_and_rw_bits and made static.
13040	All uses updated.
13041	(i386_dr_insert_aligned_watchpoint): Renamed to
13042	i386_insert_aligned_watchpoint and made static.
13043	All uses updated.
13044	(i386_dr_remove_aligned_watchpoint): Renamed to
13045	i386_remove_aligned_watchpoint and made static.
13046	All uses updated.
13047	(i386_dr_update_inferior_debug_regs): Renamed to
13048	i386_update_inferior_debug_regs and made static.
13049	All uses updated.
13050
130512014-06-18  Gary Benson  <gbenson@redhat.com>
13052
13053	* i386-low.h (i386_dr_low_can_set_addr): New macro.
13054	(i386_dr_low_can_set_control): Likewise.
13055	(i386_get_debug_register_length): Likewise.
13056	* i386-low.c (i386_dr_low_can_set_addr): Now in i386-low.h.
13057	(i386_dr_low_can_set_control): Likewise.
13058	(i386_get_debug_register_length): Likewise.
13059
130602014-06-17  Gary Benson  <gbenson@redhat.com>
13061
13062	* i386-low.h (i386-dregs.h): New include.
13063	(DR_FIRSTADDR): Now in i386-dregs.h.
13064	(DR_LASTADDR): Likewise.
13065	(DR_NADDR): Likewise.
13066	(DR_STATUS): Likewise.
13067	(DR_CONTROL): Likewise.
13068	(i386_debug_reg_state): Likewise.
13069	(i386_dr_insert_watchpoint): Likewise.
13070	(i386_dr_remove_watchpoint): Likewise.
13071	(i386_dr_region_ok_for_watchpoint): Likewise.
13072	(i386_dr_stopped_data_address): Likewise.
13073	(i386_dr_stopped_by_watchpoint): Likewise.
13074	* i386-low.c (ALL_DEBUG_REGISTERS): Likewise.
13075
130762014-06-18  Gary Benson  <gbenson@redhat.com>
13077
13078	* i386-low.h (i386_low_insert_watchpoint): Renamed to
13079	i386_dr_insert_watchpoint.
13080	(i386_low_remove_watchpoint): Renamed to
13081	i386_dr_remove_watchpoint.
13082	(i386_low_region_ok_for_watchpoint): Renamed to
13083	i386_dr_region_ok_for_watchpoint.
13084	(i386_low_stopped_data_address): Renamed to
13085	i386_dr_stopped_data_address.
13086	(i386_low_stopped_by_watchpoint): Renamed to
13087	i386_dr_stopped_by_watchpoint.
13088	* i386-low.c (i386_show_dr): Renamed to
13089	i386_dr_show and made nonstatic.  All uses updated.
13090	(i386_length_and_rw_bits): Renamed to
13091	i386_dr_length_and_rw_bits and made nonstatic.
13092	All uses updated.
13093	(i386_insert_aligned_watchpoint): Renamed to
13094	i386_dr_insert_aligned_watchpoint and made nonstatic.
13095	All uses updated.
13096	(i386_remove_aligned_watchpoint): Renamed to
13097	i386_dr_remove_aligned_watchpoint and made nonstatic.
13098	All uses updated.
13099	(i386_update_inferior_debug_regs): Renamed to
13100	i386_dr_update_inferior_debug_regs and made nonstatic.
13101	All uses updated.
13102	(i386_low_insert_watchpoint): Renamed to
13103	i386_dr_insert_watchpoint.  All uses updated.
13104	(i386_low_remove_watchpoint): Renamed to
13105	i386_dr_remove_watchpoint.  All uses updated.
13106	(i386_low_region_ok_for_watchpoint): Renamed to
13107	i386_dr_region_ok_for_watchpoint.  All uses updated.
13108	(i386_low_stopped_data_address): Renamed to
13109	i386_dr_stopped_data_address.  All uses updated.
13110	(i386_low_stopped_by_watchpoint): Renamed to
13111	i386_dr_stopped_by_watchpoint.  All uses updated.
13112
131132014-06-18  Gary Benson  <gbenson@redhat.com>
13114
13115	* i386-low.c (i386_dr_low_can_set_addr): New macro.
13116	(i386_dr_low_can_set_control): Likewise.
13117	(i386_insert_aligned_watchpoint): New check.
13118
131192014-06-18  Gary Benson  <gbenson@redhat.com>
13120
13121	* i386-low.c (i386_update_inferior_debug_regs) <inf_state>:
13122	Renamed to state.
13123
131242014-06-18  Gary Benson  <gbenson@redhat.com>
13125
13126	* i386-low.c (i386_length_and_rw_bits): Use internal_error
13127	instead of fatal and error.
13128	(i386_handle_nonaligned_watchpoint): Likewise.
13129
131302014-06-18  Gary Benson  <gbenson@redhat.com>
13131
13132	* i386-low.c (i386_get_debug_register_length): New macro.
13133	(TARGET_HAS_DR_LEN_8): Remove conditional.  Use above macro.
13134	(i386_show_dr): Use debug_printf instead of fprintf.  Use
13135	phex to format values.
13136
131372014-06-18  Gary Benson  <gbenson@redhat.com>
13138
13139	* i386-low.h: Comment changes.
13140	* i386-low.c: Likewise.
13141
131422014-06-18  Gary Benson  <gbenson@redhat.com>
13143
13144	* i386-low.c: Whitespace changes.
13145
131462014-06-12  Tom Tromey  <tromey@redhat.com>
13147
13148	* utils.c (freeargv): Remove.
13149
131502014-06-12  Tom Tromey  <tromey@redhat.com>
13151
13152	* debug.c (debug_printf): Remove HAVE_GETTIMEOFDAY checks.
13153	* server.c (monitor_show_help): Remove HAVE_GETTIMEOFDAY check.
13154	(parse_debug_format_options): Likewise.
13155	(gdbserver_usage): Likewise.
13156	* Makefile.in (LIBIBERTY_BUILDDIR, LIBIBERTY): New variables.
13157	(SUBDIRS, REQUIRED_SUBDIRS): Add libiberty.
13158	(gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Depend on and link
13159	against libiberty.
13160	($(LIBGNU)): Depend on libiberty.
13161	(all-lib): Recurse into all subdirs.
13162	(install-only): Invoke "install" target in subdirs.
13163	(vasprintf.o, vsnprintf.o, safe-ctype.o, lbasename.o): Remove
13164	targets.
13165	* configure: Rebuild.
13166	* configure.ac: Add ACX_CONFIGURE_DIR for libiberty.  Don't check
13167	for vasprintf, vsnprintf, or gettimeofday.
13168	* configure.srv: Don't add safe-ctype.o or lbasename.o to
13169	srv_tgtobj.
13170
131712014-06-05  Joel Brobecker  <brobecker@adacore.com>
13172
13173	* development.sh: Delete.
13174	* Makefile.in (config.status): Adjust dependency on development.sh.
13175	* configure.ac: Adjust development.sh source call.
13176	* configure: Regenerate.
13177
131782014-06-02  Pedro Alves  <palves@redhat.com>
13179
13180	* ax.c (gdb_free_agent_expr): New function.
13181	* ax.h (gdb_free_agent_expr): New declaration.
13182	* mem-break.c (delete_gdb_breakpoint_1): Also clear the commands
13183	list.
13184	(clear_breakpoint_conditions, clear_breakpoint_commands): Make
13185	static.
13186	(clear_breakpoint_conditions_and_commands): New function.
13187	* mem-break.h (clear_breakpoint_conditions): Delete declaration.
13188	(clear_breakpoint_conditions_and_commands): New declaration.
13189
131902014-05-23  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
13191
13192	* linux-aarch64-low.c (asm/ptrace.h): Include.
13193
131942014-05-21  Jan Kratochvil  <jan.kratochvil@redhat.com>
13195
13196	Fix TLS access for -static -pthread.
13197	* gdbserver/thread-db.c (struct thread_db): Add td_thr_tlsbase_p.
13198	(thread_db_get_tls_address): Call it if LOAD_MODULE is zero.
13199	(thread_db_load_search, try_thread_db_load_1): Initialize it.
13200
132012014-05-20  Pedro Alves  <palves@redhat.com>
13202
13203	* linux-aarch64-low.c (aarch64_insert_point)
13204	(aarch64_remove_point): No longer check whether the type is
13205	supported here.  Adjust to new interface.
13206	(the_low_target): Install aarch64_supports_z_point_type as
13207	supports_z_point_type method.
13208	* linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type): New function.
13209	(arm_linux_hw_point_initialize): Take an enum raw_bkpt_type
13210	instead of a Z packet char.  Adjust.
13211	(arm_supports_z_point_type): New function.
13212	(arm_insert_point, arm_remove_point): Adjust to new interface.
13213	(the_low_target): Install arm_supports_z_point_type.
13214	* linux-crisv32-low.c (cris_supports_z_point_type): New function.
13215	(cris_insert_point, cris_remove_point): Adjust to new interface.
13216	Don't check whether the type is supported here.
13217	(the_low_target): Install cris_supports_z_point_type.
13218	* linux-low.c (linux_supports_z_point_type): New function.
13219	(linux_insert_point, linux_remove_point): Adjust to new interface.
13220	* linux-low.h (struct linux_target_ops) <insert_point,
13221	remove_point>: Take an enum raw_bkpt_type instead of a char.  Add
13222	raw_breakpoint pointer parameter.
13223	<supports_z_point_type>: New method.
13224	* linux-mips-low.c (mips_supports_z_point_type): New function.
13225	(mips_insert_point, mips_remove_point): Adjust to new interface.
13226	Use mips_supports_z_point_type.
13227	(the_low_target): Install mips_supports_z_point_type.
13228	* linux-ppc-low.c (the_low_target): Install NULL as
13229	supports_z_point_type method.
13230	* linux-s390-low.c (the_low_target): Install NULL as
13231	supports_z_point_type method.
13232	* linux-sparc-low.c (the_low_target): Install NULL as
13233	supports_z_point_type method.
13234	* linux-x86-low.c (x86_supports_z_point_type): New function.
13235	(x86_insert_point): Adjust to new insert_point interface.  Use
13236	insert_memory_breakpoint.  Adjust to new
13237	i386_low_insert_watchpoint interface.
13238	(x86_remove_point): Adjust to remove_point interface.  Use
13239	remove_memory_breakpoint.  Adjust to new
13240	i386_low_remove_watchpoint interface.
13241	(the_low_target): Install x86_supports_z_point_type.
13242	* lynx-low.c (lynx_target_ops): Install NULL as
13243	supports_z_point_type callback.
13244	* nto-low.c (nto_supports_z_point_type): New.
13245	(nto_insert_point, nto_remove_point): Adjust to new interface.
13246	(nto_target_ops): Install nto_supports_z_point_type.
13247	* mem-break.c: Adjust intro comment.
13248	(struct raw_breakpoint) <raw_type, size>: New fields.
13249	<inserted>: Update comment.
13250	<shlib_disabled>: Delete field.
13251	(enum bkpt_type) <gdb_breakpoint>: Delete value.
13252	<gdb_breakpoint_Z0, gdb_breakpoint_Z1, gdb_breakpoint_Z2,
13253	gdb_breakpoint_Z3, gdb_breakpoint_Z4>: New values.
13254	(raw_bkpt_type_to_target_hw_bp_type): New function.
13255	(find_enabled_raw_code_breakpoint_at): New function.
13256	(find_raw_breakpoint_at): New type and size parameters.  Use them.
13257	(insert_memory_breakpoint): New function, based off
13258	set_raw_breakpoint_at.
13259	(remove_memory_breakpoint): New function.
13260	(set_raw_breakpoint_at): Reimplement.
13261	(set_breakpoint): New, based on set_breakpoint_at.
13262	(set_breakpoint_at): Reimplement.
13263	(delete_raw_breakpoint): Go through the_target->remove_point
13264	instead of assuming memory breakpoints.
13265	(find_gdb_breakpoint_at): Delete.
13266	(Z_packet_to_bkpt_type, Z_packet_to_raw_bkpt_type): New functions.
13267	(find_gdb_breakpoint): New function.
13268	(set_gdb_breakpoint_at): Delete.
13269	(z_type_supported): New function.
13270	(set_gdb_breakpoint_1): New function, loosely based off
13271	set_gdb_breakpoint_at.
13272	(check_gdb_bp_preconditions, set_gdb_breakpoint): New functions.
13273	(delete_gdb_breakpoint_at): Delete.
13274	(delete_gdb_breakpoint_1): New function, loosely based off
13275	delete_gdb_breakpoint_at.
13276	(delete_gdb_breakpoint): New function.
13277	(clear_gdb_breakpoint_conditions): Rename to ...
13278	(clear_breakpoint_conditions): ... this.  Don't handle a NULL
13279	breakpoint.
13280	(add_condition_to_breakpoint): Make static.
13281	(add_breakpoint_condition): Take a struct breakpoint pointer
13282	instead of an address.  Adjust.
13283	(gdb_condition_true_at_breakpoint): Rename to ...
13284	(gdb_condition_true_at_breakpoint_z_type): ... this, and add
13285	z_type parameter.
13286	(gdb_condition_true_at_breakpoint): Reimplement.
13287	(add_breakpoint_commands): Take a struct breakpoint pointer
13288	instead of an address.  Adjust.
13289	(gdb_no_commands_at_breakpoint): Rename to ...
13290	(gdb_no_commands_at_breakpoint_z_type): ... this.  Add z_type
13291	parameter.  Return true if no breakpoint was found.  Change debug
13292	output.
13293	(gdb_no_commands_at_breakpoint): Reimplement.
13294	(run_breakpoint_commands): Rename to ...
13295	(run_breakpoint_commands_z_type): ... this.  Add z_type parameter,
13296	and change return type to boolean.
13297	(run_breakpoint_commands): New function.
13298	(gdb_breakpoint_here): Also check for Z1 breakpoints.
13299	(uninsert_raw_breakpoint): Don't try to reinsert a disabled
13300	breakpoint.  Go through the_target->remove_point instead of
13301	assuming memory breakpoint.
13302	(uninsert_breakpoints_at, uninsert_all_breakpoints): Uninsert
13303	software and hardware breakpoints.
13304	(reinsert_raw_breakpoint): Go through the_target->insert_point
13305	instead of assuming memory breakpoint.
13306	(reinsert_breakpoints_at, reinsert_all_breakpoints): Reinsert
13307	software and hardware breakpoints.
13308	(check_breakpoints, breakpoint_here, breakpoint_inserted_here):
13309	Check both software and hardware breakpoints.
13310	(validate_inserted_breakpoint): Assert the breakpoint is a
13311	software breakpoint.  Set the inserted flag to -1 instead of
13312	setting shlib_disabled.
13313	(delete_disabled_breakpoints): Adjust.
13314	(validate_breakpoints): Only validate software breakpoints.
13315	Adjust to inserted flag change.
13316	(check_mem_read, check_mem_write): Skip breakpoint types other
13317	than software breakpoints.  Adjust to inserted flag change.
13318	* mem-break.h (enum raw_bkpt_type): New enum.
13319	(raw_breakpoint, struct process_info): Forward declare.
13320	(Z_packet_to_target_hw_bp_type): Delete declaration.
13321	(raw_bkpt_type_to_target_hw_bp_type, Z_packet_to_raw_bkpt_type)
13322	(set_gdb_breakpoint, delete_gdb_breakpoint)
13323	(clear_breakpoint_conditions): New declarations.
13324	(set_gdb_breakpoint_at, clear_gdb_breakpoint_conditions): Delete.
13325	(breakpoint_inserted_here): Update comment.
13326	(add_breakpoint_condition, add_breakpoint_commands): Replace
13327	address parameter with a breakpoint pointer parameter.
13328	(gdb_breakpoint_here): Update comment.
13329	(delete_gdb_breakpoint_at): Delete.
13330	(insert_memory_breakpoint, remove_memory_breakpoint): Declare.
13331	* server.c (process_point_options): Take a struct breakpoint
13332	pointer instead of an address.  Adjust.
13333	(process_serial_event) <Z/z packets>: Use set_gdb_breakpoint and
13334	delete_gdb_breakpoint.
13335	* spu-low.c (spu_target_ops): Install NULL as
13336	supports_z_point_type method.
13337	* target.h: Include mem-break.h.
13338	(struct target_ops) <prepare_to_access_memory>: Update comment.
13339	<supports_z_point_type>: New field.
13340	<insert_point, remove_point>: Take an enum raw_bkpt_type argument
13341	instead of a char.  Also take a raw breakpoint pointer.
13342	* win32-arm-low.c (the_low_target): Install NULL as
13343	supports_z_point_type.
13344	* win32-i386-low.c (i386_supports_z_point_type): New function.
13345	(i386_insert_point, i386_remove_point): Adjust to new interface.
13346	(the_low_target): Install i386_supports_z_point_type.
13347	* win32-low.c (win32_supports_z_point_type): New function.
13348	(win32_insert_point, win32_remove_point): Adjust to new interface.
13349	(win32_target_ops): Install win32_supports_z_point_type.
13350	* win32-low.h (struct win32_target_ops):
13351	<supports_z_point_type>: New method.
13352	<insert_point, remove_point>: Take an enum raw_bkpt_type argument
13353	instead of a char.  Also take a raw breakpoint pointer.
13354
133552014-05-20  Pedro Alves  <palves@redhat.com>
13356
13357	* mem-break.h: Include break-common.h.
13358	(Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
13359	(Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): New defines.
13360	(Z_packet_to_target_hw_bp_type): New declaration.
13361	* mem-break.c (Z_packet_to_target_hw_bp_type): New function.
13362	* i386-low.c (Z_PACKET_HW_BP, Z_PACKET_WRITE_WP, Z_PACKET_READ_WP)
13363	(Z_PACKET_ACCESS_WP): Delete macros.
13364	(Z_packet_to_hw_type): Delete function.
13365	* i386-low.h: Don't include break-common.h here.
13366	(Z_packet_to_hw_type): Delete declaration.
13367	* linux-x86-low.c (x86_insert_point, x86_insert_point): Call
13368	Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
13369	* win32-i386-low.c (i386_insert_point, i386_remove_point): Call
13370	Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
13371	* linux-aarch64-low.c: Don't include break-common.h here.
13372	(Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
13373	(Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): Delete macros.
13374	(Z_packet_to_target_hw_bp_type): Delete function.
13375	* linux-mips-low.c (rsp_bp_type_to_target_hw_bp_type): Delete
13376	function.
13377	(mips_insert_point, mips_remove_point): Use
13378	Z_packet_to_target_hw_bp_type.
13379
133802014-05-20  Pedro Alves  <palves@redhat.com>
13381
13382	* linux-aarch64-low.c: Include break-common.h.
13383	(enum target_point_type): Delete.
13384	(Z_packet_to_point_type): Rename to ...
13385	(Z_packet_to_target_hw_bp_type): ... this, and return a
13386	target_hw_bp_type instead.
13387	(aarch64_show_debug_reg_state): Take an enum target_hw_bp_type
13388	instead of an enum target_point_type.
13389	(aarch64_point_encode_ctrl_reg): Likewise.  Compute type mask from
13390	breakpoint type.
13391	(aarch64_dr_state_insert_one_point)
13392	(aarch64_dr_state_remove_one_point, aarch64_handle_breakpoint)
13393	(aarch64_handle_aligned_watchpoint)
13394	(aarch64_handle_unaligned_watchpoint, aarch64_handle_watchpoint):
13395	Take an enum target_hw_bp_type instead of an enum
13396	target_point_type.
13397	(aarch64_supports_z_point_type): New function.
13398	(aarch64_insert_point, aarch64_remove_point): Use it.  Adjust to
13399	use Z_packet_to_target_hw_bp_type.
13400
134012014-05-20  Joel Brobecker  <brobecker@adacore.com>
13402
13403	* configure.ac: Only use -Werror by default when DEVELOPMENT
13404	is true.
13405	* configure: Regenerate.
13406
134072014-05-19  Jan Kratochvil  <jan.kratochvil@redhat.com>
13408
13409	Fix gdbserver qGetTLSAddr for x86_64 -m32.
13410	* linux-x86-low.c (X86_64_USER_REGS): New.
13411	(x86_fill_gregset): Call memset for BUF first in x86_64 -m32 case.
13412
134132014-04-28  Yao Qi  <yao@codesourcery.com>
13414
13415	* Makefile.in (i386-avx512.c): Fix the typo of generated file
13416	name.
13417
134182014-04-25  Pedro Alves  <palves@redhat.com>
13419
13420	PR server/16255
13421	* linux-low.c (linux_attach_fail_reason_string): New function.
13422	(linux_attach_lwp): Delete.
13423	(linux_attach_lwp_1): Rename to ...
13424	(linux_attach_lwp): ... this.  Take a ptid instead of a pid as
13425	argument.  Remove "initial" parameter.  Return int instead of
13426	void.  Don't error or warn here.
13427	(linux_attach): Adjust to call linux_attach_lwp.  Call error on
13428	failure to attach to the tgid.  Call warning when failing to
13429	attach to an lwp.
13430	* linux-low.h (linux_attach_lwp): Take a ptid instead of a pid as
13431	argument.  Remove "initial" parameter.  Return int instead of
13432	void.  Don't error or warn here.
13433	(linux_attach_fail_reason_string): New declaration.
13434	* thread-db.c (attach_thread): Adjust to linux_attach_lwp's
13435	interface change.  Use linux_attach_fail_reason_string.
13436
134372014-04-24  Michael Sturm  <michael.sturm@mintel.com>
13438	    Walfred Tedeschi  <walfred.tedeschi@intel.com>
13439
13440	* Makefile.in: Added rules to handle new files
13441	i386-avx512.c i386-avx512-linux.c amd64-avx512.c
13442	amd64-avx512-linux.c x32-avx512.c x32-avx512-linux.c.
13443	* configure.srv (srv_i386_regobj): Add i386-avx512.o.
13444	(srv_i386_linux_regobj): Add i386-avx512-linux.o.
13445	(srv_amd64_regobj): Add amd64-avx512.o and x32-avx512.o.
13446	(srv_amd64_linux_regobj): Add amd64-avx512-linux.o and
13447	x32-avx512-linux.o.
13448	(srv_i386_32bit_xmlfiles): Add i386/32bit-avx512.xml.
13449	(srv_i386_64bit_xmlfiles): Add i386/64bit-avx512.xml.
13450	(srv_amd64_xmlfiles): Add i386/amd64-avx512.xml and
13451	i386/x32-avx512.xml.
13452	(srv_i386_linux_xmlfiles): Add i386/i386-avx512-linux.xml.
13453	(srv_amd64_linux_xmlfiles): Add i386/amd64-avx512-linux.xml and
13454	i386/x32-avx512-linux.xml.
13455	* i387-fp.c (num_avx512_k_registers): New constant for number
13456	of K registers.
13457	(num_avx512_zmmh_low_registers): New constant for number of
13458	lower ZMM registers (0-15).
13459	(num_avx512_zmmh_high_registers): New constant for number of
13460	higher ZMM registers (16-31).
13461	(num_avx512_ymmh_registers): New contant for number of higher
13462	YMM registers (ymm16-31 added by avx521 on x86_64).
13463	(num_avx512_xmm_registers): New constant for number of higher
13464	XMM registers (xmm16-31 added by AVX512 on x86_64).
13465	(struct i387_xsave): Add space for AVX512 registers.
13466	(i387_cache_to_xsave): Change raw buffer size to 64 characters.
13467	Add code to handle AVX512 registers.
13468	(i387_xsave_to_cache): Add code to handle AVX512 registers.
13469	* linux-x86-low.c (init_registers_amd64_avx512_linux): New
13470	prototypei from generated file.
13471	(tdesc_amd64_avx512_linux): Likewise.
13472	(init_registers_x32_avx512_linux): Likewise.
13473	(tdesc_x32_avx512_linux): Likewise.
13474	(init_registers_i386_avx512_linux): Likewise.
13475	(tdesc_i386_avx512_linux): Likewise.
13476	(x86_64_regmap): Add AVX512 registers.
13477	(x86_linux_read_description): Add code to handle AVX512 XSTATE
13478	mask.
13479	(initialize_low_arch): Add code to initialize AVX512 registers.
13480
134812014-04-23  Pedro Alves  <palves@redhat.com>
13482
13483	* mem-break.c (find_gdb_breakpoint_at): Make static.
13484	* mem-break.h (find_gdb_breakpoint_at): Delete declaration.
13485
134862014-04-23  Pedro Alves  <palves@redhat.com>
13487
13488	* i386-low.c: Don't include break-common.h here.
13489	(i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
13490	prototype to take target_hw_bp_type as argument instead of a Z
13491	packet char.
13492	* i386-low.h: Include break-common.h here.
13493	(Z_packet_to_hw_type): Declare.
13494	(i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
13495	prototypes.
13496	* linux-x86-low.c (x86_insert_point): Convert the packet number to
13497	a target_hw_bp_type before calling i386_low_insert_watchpoint.
13498	(x86_remove_point): Convert the packet number to a
13499	target_hw_bp_type before calling i386_low_remove_watchpoint.
13500	* win32-i386-low.c (i386_insert_point): Convert the packet number
13501	to a target_hw_bp_type before calling i386_low_insert_watchpoint.
13502	(i386_remove_point): Convert the packet number to a
13503	target_hw_bp_type before calling i386_low_remove_watchpoint.
13504
135052014-04-23  Pedro Alves  <palves@redhat.com>
13506
13507	* utils.h (perror_with_name): Add ATTRIBUTE_NORETURN.
13508
135092014-04-10  Pedro Alves  <palves@redhat.com>
13510
13511	* mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
13512	Check if the condition or command is NULL before checking if the
13513	breakpoint is known.  On success, return true.
13514	* mem-break.h (add_breakpoint_condition): Document return.
13515	(add_breakpoint_commands): Add describing comment.
13516	* server.c (skip_to_semicolon): New function.
13517	(process_point_options): Use it.
13518
135192014-04-09  Pedro Alves  <palves@redhat.com>
13520
13521	* linux-low.c (linux_read_loadmap): Pass current_inferior directly
13522	to lwpid_of.
13523
135242014-02-27  Pedro Alves  <palves@redhat.com>
13525
13526	PR 12702
13527	* inferiors.h (A_I_NEXT, ALL_INFERIORS_TYPE, ALL_PROCESSES): New
13528	macros.
13529	* linux-low.c (delete_lwp, handle_extended_wait): Add debug
13530	output.
13531	(last_thread_of_process_p): Take a PID argument instead of a
13532	thread pointer.
13533	(linux_wait_for_lwp): Delete.
13534	(num_lwps, check_zombie_leaders, not_stopped_callback): New
13535	functions.
13536	(linux_low_filter_event): New function, party factored out from
13537	linux_wait_for_event.
13538	(linux_wait_for_event): Rename to ...
13539	(linux_wait_for_event_filtered): ... this.  Add new filter ptid
13540	argument.  Partly rewrite.  Always use waitpid(-1, WNOHANG) and
13541	sigsuspend.  Check for zombie leaders.
13542	(linux_wait_for_event): Reimplement as wrapper around
13543	linux_wait_for_event_filtered.
13544	(linux_wait_1): Handle TARGET_WAITKIND_NO_RESUMED.  Assume that if
13545	a normal or signal exit is seen, it's the whole process exiting.
13546	(wait_for_sigstop): No longer a for_each_inferior callback.
13547	Rewrite on top of linux_wait_for_event_filtered.
13548	(stop_all_lwps): Call wait_for_sigstop directly.
13549	* server.c (resume, handle_target_event): Handle
13550	TARGET_WAITKIND_NO_RESUMED.
13551
135522014-02-26  Joel Brobecker  <brobecker@adacore.com>
13553
13554	* win32-low.c (psapi_get_dll_name,
13555	* win32_CreateToolhelp32Snapshot): Delete.
13556	(win32_CreateToolhelp32Snapshot, win32_Module32First)
13557	(win32_Module32Next, load_toolhelp, toolhelp_get_dll_name):
13558	Delete.
13559	(handle_load_dll): Add function description.
13560	Remove code using psapi_get_dll_name and toolhelp_get_dll_name.
13561
135622014-02-26  Joel Brobecker  <brobecker@adacore.com>
13563
13564	* win32-low.c (win32_add_one_solib): Add 0x1000 to load_addr.
13565	Add comment.
13566	(win32_add_all_dlls): Remove 0x1000 offset applied to DLL
13567	base address when calling win32_add_one_solib.
13568	(handle_load_dll): Delete local variable load_addr.
13569	Remove 0x1000 offset applied to DLL base address when calling
13570	win32_add_one_solib.
13571	(handle_unload_dll): Add comment.
13572
135732014-02-26  Joel Brobecker  <brobecker@adacore.com>
13574
13575	* win32-low.c (win32_add_all_dlls): Renames
13576	win32_ensure_ntdll_loaded.  Rewrite function documentation.
13577	Adjust implementation to always load all DLLs.
13578	Add 0x1000 offset to DLL base address when calling
13579	win32_add_one_solib.
13580	(child_initialization_done): New static global.
13581	(do_initial_child_stuff): Set child_initialization_done to
13582	zero during child initialization, and 1 after.  Replace call
13583	to win32_ensure_ntdll_loaded by call to win32_add_all_dlls.
13584	Add comment.
13585	(match_dll_by_basename, dll_is_loaded_by_basename): Delete.
13586	(handle_unload_dll): Add function documentation.
13587	(get_child_debug_event): Ignore load and unload DLL events
13588	during child initialization.
13589
135902014-02-20  Doug Evans  <dje@google.com>
13591
13592	Remove global all_lwps.
13593	* inferiors.h (ptid_of): Move here from linux-low.h.
13594	(pid_of, lwpid_of): Ditto.
13595	* linux-aarch64-low.c (debug_reg_change_callback): Update, "entry"
13596	parameter is a struct thread_info * now.
13597	(aarch64_notify_debug_reg_change): Fetch pid from current_inferior
13598	directly.  Pass &all_threads to find_inferior instead of &all_lwps.
13599	(aarch64_stopped_data_address): Fetch lwpid from current_inferior
13600	directly.
13601	(aarch64_linux_prepare_to_resume): Fetch ptid from thread.
13602	(aarch64_arch_setup): Fetch lwpid from current_inferior directly.
13603	* linux-arm-low.c (update_registers_callback): Update, "entry"
13604	parameter is a struct thread_info * now.
13605	Fetch lwpid from current_inferior directly.
13606	(arm_insert_point): Pass &all_threads to find_inferior instead of
13607	&all_lwps.
13608	(arm_remove_point): Ditto.
13609	(arm_stopped_by_watchpoint): Fetch lwp from current_inferior.
13610	(arm_prepare_to_resume): Fetch pid from thread.
13611	(arm_read_description): Fetch lwpid from current_inferior directly.
13612	* linux-low.c (all_lwps): Delete.
13613	(delete_lwp): Delete call to remove_inferior.
13614	(handle_extended_wait): Fetch lwpid from thread.
13615	(add_lwp): Don't set lwp->entry.id.  Remove call to
13616	add_inferior_to_list.
13617	(linux_attach_lwp_1): Fetch pid from current_inferior directly.
13618	(linux_kill_one_lwp): Fetch ptid,lwpid from thread.
13619	(kill_one_lwp_callback): Ditto.
13620	(linux_kill): Don't dereference NULL pointer.
13621	Fetch ptid,lwpid from thread.
13622	(get_detach_signal): Fetch ptid from thread.
13623	(linux_detach_one_lwp): Fetch ptid,lwpid from thread.
13624	Simplify call to regcache_invalidate_thread.
13625	(delete_lwp_callback): Update, "entry" parameter is a
13626	struct thread_info * now.  Fetch pid from thread.
13627	(linux_mourn): Pass &all_threads to find_inferior instead of &all_lwps.
13628	(status_pending_p_callback): Update, "entry" parameter is a
13629	struct thread_info * now.  Fetch ptid from thread.
13630	(find_lwp_pid): Update, "entry" parameter is a
13631	struct thread_info * now.
13632	(linux_wait_for_lwp): Fetch pid from thread.
13633	(linux_fast_tracepoint_collecting): Fetch lwpid from thread.
13634	(maybe_move_out_of_jump_pad): Fetch lwpid from current_inferior.
13635	(enqueue_one_deferred_signal): Fetch lwpid from thread.
13636	(dequeue_one_deferred_signal): Ditto.
13637	(cancel_breakpoint): Fetch ptid from current_inferior.
13638	(linux_wait_for_event): Pass &all_threads to find_inferior,
13639	not &all_lwps.  Fetch ptid, lwpid from thread.
13640	(count_events_callback): Update, "entry" parameter is a
13641	struct thread_info * now.
13642	(select_singlestep_lwp_callback): Ditto.
13643	(select_event_lwp_callback): Ditto.
13644	(cancel_breakpoints_callback): Ditto.
13645	(linux_cancel_breakpoints): Pass &all_threads to find_inferior,
13646	not &all_lwps.
13647	(select_event_lwp): Ditto.  Fetch ptid from event_thread.
13648	(unsuspend_one_lwp): Update, "entry" parameter is a
13649	struct thread_info * now.
13650	(unsuspend_all_lwps): Pass &all_threads to find_inferior,
13651	not &all_lwps.
13652	(linux_stabilize_threads): Ditto.  And for for_each_inferior.
13653	Fetch lwpid from thread, not lwp.
13654	(linux_wait_1): Fetch ptid, lwpid from current_inferior.
13655	Pass &all_threads to find_inferior, not &all_lwps.
13656	(send_sigstop): Fetch lwpid from thread, not lwp.
13657	(send_sigstop_callback): Update, "entry" parameter is a
13658	struct thread_info * now.
13659	(suspend_and_send_sigstop_callback): Ditto.
13660	(wait_for_sigstop): Ditto.  Fetch ptid, lwpid from thread, lwp.
13661	(stuck_in_jump_pad_callback): Update, "entry" parameter is a
13662	struct thread_info * now.
13663	(move_out_of_jump_pad_callback): Ditto.  Fetch ptid, lwpid
13664	from thread, lwp.
13665	(lwp_running): Update, "entry" parameter is a
13666	struct thread_info * now.
13667	(stop_all_lwps): Fetch ptid from thread.
13668	Pass &all_threads to find_inferior, for_each_inferior, not &all_lwps.
13669	(linux_resume_one_lwp): Fetch lwpid from thread.
13670	(linux_set_resume_request): Update, "entry" parameter is a
13671	struct thread_info * now.  Fetch pid, lwpid from thread.
13672	(resume_status_pending_p): Update, "entry" parameter is a
13673	struct thread_info * now.
13674	(need_step_over_p): Ditto.  Fetch lwpid from thread.
13675	(start_step_over): Fetch lwpid from thread.
13676	(linux_resume_one_thread): Update, "entry" parameter is a
13677	struct thread_info * now.  Fetch lwpid from thread.
13678	(linux_resume): Pass &all_threads to find_inferior, not &all_lwps.
13679	(proceed_one_lwp): Update, "entry" parameter is a
13680	struct thread_info * now.  Fetch lwpid from thread.
13681	(unsuspend_and_proceed_one_lwp): Update, "entry" parameter is a
13682	struct thread_info * now.
13683	(proceed_all_lwps): Pass &all_threads to find_inferior, not &all_lwps.
13684	(unstop_all_lwps): Ditto.  Fetch lwpid from thread.
13685	(regsets_fetch_inferior_registers): Fetch lwpid from current_inferior
13686	directly.
13687	(regsets_store_inferior_registers): Ditto.
13688	(fetch_register, store_register): Ditto.
13689	(linux_read_memory, linux_write_memory): Ditto.
13690	(linux_request_interrupt): Ditto.
13691	(linux_read_auxv): Ditto.
13692	(linux_xfer_siginfo): Ditto.
13693	(linux_qxfer_spu): Ditto.
13694	(linux_qxfer_libraries_svr4): Ditto.
13695	* linux-low.h (ptid_of, pid_of, lwpid_of): Delete,
13696	moved to inferiors.h.
13697	(get_lwp): Delete.
13698	(get_thread_lwp): Update.
13699	(struct lwp_info): Delete member "entry".  Simplify comment for
13700	member "thread".
13701	(all_lwps): Delete.
13702	* linux-mips-low.c (mips_read_description): Fetch lwpid from
13703	current_inferior directly.
13704	(update_watch_registers_callback): Update, "entry" parameter is a
13705	struct thread_info * now.  Fetch pid from thread.
13706	(mips_linux_prepare_to_resume): Fetch ptid from thread.
13707	(mips_insert_point): Fetch lwpid from current_inferior.
13708	Pass &all_threads to find_inferior, not &all_lwps.
13709	(mips_remove_point): Pass &all_threads to find_inferior, not &all_lwps.
13710	(mips_stopped_by_watchpoint): Fetch lwpid from current_inferior
13711	directly.
13712	(mips_stopped_data_address): Ditto.
13713	* linux-s390-low.c (s390_arch_setup): Fetch pid from current_inferior
13714	directly.
13715	* linux-tile-low.c (tile_arch_setup): Ditto.
13716	* linux-x86-low.c (x86_get_thread_area): Fetch lwpid from thread.
13717	(update_debug_registers_callback): Update, "entry" parameter is a
13718	struct thread_info * now.  Fetch pid from thread.
13719	(i386_dr_low_set_addr): Fetch pid from current_inferior directly.
13720	Pass &all_threads to find_inferior, not &all_lwps.
13721	(i386_dr_low_get_addr): Fetch ptid from current_inferior directly.
13722	(i386_dr_low_set_control): Fetch pid from current_inferior directly.
13723	Pass &all_threads to find_inferior, not &all_lwps.
13724	(i386_dr_low_get_control): Fetch ptid from current_inferior directly.
13725	(i386_dr_low_get_status): Ditto.
13726	(x86_linux_prepare_to_resume): Fetch ptid from thread.
13727	(x86_siginfo_fixup): Fetch lwpid from current_inferior directly.
13728	(x86_linux_read_description): Ditto.
13729	* proc-service.c (ps_getpid): Fetch pid from current_inferior directly.
13730
137312014-02-20  Doug Evans  <dje@google.com>
13732
13733	* inferiors.c (get_first_inferior): Fix buglet.
13734
137352014-02-19  Doug Evans  <dje@google.com>
13736
13737	* gdbthread.h (add_thread): Change result type to struct thread_info *.
13738	* inferiors.c (add_thread): Change result type to struct thread_info *.
13739	All callers updated.
13740	(add_lwp): Call add_thread here instead of in callers.
13741	All callers updated.
13742	* linux-low.h (get_lwp_thread): Rewrite.
13743	(struct lwp_info): New member "thread".
13744
137452014-02-19  Doug Evans  <dje@google.com>
13746
13747	* linux-low.c (add_lwp): Change result to struct lwp_info *.
13748	All callers updated.
13749
137502014-02-19  Doug Evans  <dje@google.com>
13751
13752	* inferiors.c (add_thread): Fix whitespace.
13753
137542014-02-19  Doug Evans  <dje@google.com>
13755
13756	* dll.c (clear_dlls): Replace accessing list implemention details
13757	with API function.
13758	* gdbthread.h (get_first_thread): Declare.
13759	* inferiors.c (for_each_inferior_with_data): New function.
13760	(get_first_thread): New function.
13761	(find_thread_ptid): Simplify.
13762	(get_first_inferior): New function.
13763	(clear_list): Delete.
13764	(one_inferior_p): New function.
13765	(clear_inferior_list): New function.
13766	(clear_inferiors): Update.
13767	* inferiors.h (for_each_inferior_with_data): Declare.
13768	(clear_inferior_list): Declare.
13769	(one_inferior_p): Declare.
13770	(get_first_inferior): Declare.
13771	* linux-low.c (linux_wait_for_event): Replace accessing list
13772	implemention details with API function.
13773	* server.c (target_running): Ditto.
13774	(accumulate_file_name_length): New function.
13775	(emit_dll_description): New function.
13776	(handle_qxfer_libraries): Replace accessing list implemention
13777	details with API function.
13778	(handle_qxfer_threads_worker): New function.
13779	(handle_qxfer_threads_proper): Replace accessing list implemention
13780	details with API function.
13781	(handle_query): Ditto.
13782	(visit_actioned_threads_callback_ftype): New typedef.
13783	(visit_actioned_threads_data): New struct.
13784	(visit_actioned_threads): Rewrite to be find_inferior callback.
13785	(resume): Call find_inferior.
13786	(handle_status): Replace accessing list implemention
13787	details with API function.
13788	(process_serial_event): Replace accessing list implemention details
13789	with API function.
13790	* target.c (set_desired_inferior): Replace accessing list implemention
13791	details with API function.
13792	* tracepoint.c (same_process_p): New function.
13793	(gdb_agent_about_to_close): Replace accessing list implemention
13794	details with API function.
13795	* win32-low.c (child_delete_thread): Replace accessing list
13796	implemention details with API function.
13797	(match_dll_by_basename): New function.
13798	(dll_is_loaded_by_basename): New function.
13799	(win32_ensure_ntdll_loaded): Replace accessing list implemention
13800	details call to dll_is_loaded_by_basename.
13801
138022014-02-19  Doug Evans  <dje@google.com>
13803
13804	* dll.h (struct dll_info): Add comment.
13805	* gdbthread.h (struct thread_info): Add comment.
13806	(current_ptid): Simplify.
13807	* inferiors.c (add_process): Update.
13808	(remove_process): Update.
13809	* inferiors.h (struct process_info): Rename member "head" to "entry".
13810	* linux-low.c (delete_lwp): Update.
13811	(add_lwp): Update.
13812	(last_thread_of_process_p): Update.
13813	(kill_one_lwp_callback, linux_kill): Update.
13814	(status_pending_p_callback): Update.
13815	(wait_for_sigstop): Update.  Simplify read of ptid.
13816	(start_step_over): Update.
13817	* linux-low.h (ptid_of, pid_of, lwpid_of): Update.
13818	(get_lwp_thread): Update.
13819	(struct lwp_info): Rename member "head" to "entry".
13820	* regcache.h (inferior_list_entry): Delete.
13821	* server.c (kill_inferior_callback): Update.
13822	(detach_or_kill_inferior_callback): Update.
13823	(print_started_pid): Update.
13824	(print_attached_pid): Update.
13825	(process_serial_event): Simplify read of ptid.
13826	* thread-db.c (thread_db_create_event): Update.
13827	(thread_db_get_tls_address): Update.
13828	* win32-low.c (current_inferior_ptid): Simplify.
13829
138302014-02-19  Tom Tromey  <tromey@redhat.com>
13831
13832	* target.h (struct target_ops) <supports_btrace>: Add target_ops
13833	argument.
13834	(target_supports_btrace): Update.
13835
138362014-02-14  Yao Qi  <yao@codesourcery.com>
13837
13838	* Makefile.in (IPA_OBJS): Append rsp-low-ipa.o.
13839	(rsp-low-ipa.o): New target.
13840
138412014-02-12  Tom Tromey  <tromey@redhat.com>
13842
13843	* ax.c (gdb_parse_agent_expr): Use hex2bin, not
13844	convert_ascii_to_int.
13845	* regcache.c (registers_to_string): Likewise.
13846	* remote-utils.c (decode_M_packet): Likewise.
13847	* server.c (process_serial_event): Likewise.
13848
138492014-02-12  Tom Tromey  <tromey@redhat.com>
13850
13851	* server.c (handle_query, handle_v_run): Use hex2bin, not
13852	unhexify.
13853	* tracepoint.c (cmd_qtdpsrc, cmd_qtdv, cmd_qtnotes): Likewise.
13854
138552014-02-12  Tom Tromey  <tromey@redhat.com>
13856
13857	* ax.c (gdb_unparse_agent_expr): Use bin2hex, not
13858	convert_int_to_ascii.
13859	* regcache.c (registers_to_string, collect_register_as_string):
13860	Likewise.
13861	* remote-utils.c (look_up_one_symbol, relocate_instruction):
13862	Likewise.
13863	* server.c (process_serial_event): Likewise.
13864	* tracepoint.c (cmd_qtstatus, response_source, response_tsv)
13865	(cmd_qtbuffer, cstr_to_hexstr): Likewise.
13866
138672014-02-12  Tom Tromey  <tromey@redhat.com>
13868
13869	* remote-utils.c (look_up_one_symbol, monitor_output): Use
13870	bin2hex, not hexify.
13871	* tracepoint.c (cmd_qtstatus): Likewise.
13872
138732014-02-12  Tom Tromey  <tromey@redhat.com>
13874
13875	* remote-utils.c (monitor_output): Pass explicit length to
13876	hexify.
13877
138782014-02-12  Tom Tromey  <tromey@redhat.com>
13879
13880	* tracepoint.c: Include rsp-low.h.
13881	* server.c: Include rsp-low.h.
13882	* remote-utils.h (convert_ascii_to_int, convert_int_to_ascii)
13883	(unhexify, hexify, remote_escape_output, unpack_varlen_hex): Don't
13884	declare.
13885	* remote-utils.c: Include rsp-low.h.
13886	(fromhex, hexchars, ishex, unhexify, tohex, hexify)
13887	(remote_escape_output, remote_unescape_input, unpack_varlen_hex)
13888	(convert_int_to_ascii, convert_ascii_to_int): Move to
13889	common/rsp-low.c.
13890	* regcache.c: Include rsp-low.h.
13891	* ax.c: Include rsp-low.h.
13892	* Makefile.in (SFILES): Add common/rsp-low.c.
13893	(OBS): Add rsp-low.o.
13894	(rsp-low.o): New target.
13895
138962014-02-12  Tom Tromey  <tromey@redhat.com>
13897
13898	* utils.h (pulongest, plongest, phex_nz): Don't declare.
13899	Include print-utils.h.
13900	* utils.c (NUMCELLS, CELLSIZE, get_cell, decimal2str, pulongest)
13901	(plongest, thirty_two, phex_nz): Remove.
13902	* Makefile.in (SFILES): Add common/print-utils.c.
13903	(OBS): Add print-utils.o.
13904	(print-utils-ipa.o): New target.
13905	(print-utils.o): New target.
13906	(IPA_OBJS): Add print-utils-ipa.o.
13907
139082014-02-06  Tom Tromey  <tromey@redhat.com>
13909
13910	* Makefile.in (SFILES): Fix indentation.
13911
139122014-02-05  Doug Evans  <dje@google.com>
13913
13914	* linux-low.c (linux_wait_for_event): Improve comment.
13915	(linux_wait_1): Keep current_inferior in sync with event_child.
13916
139172014-01-22  Doug Evans  <dje@google.com>
13918
13919	* gdbthread.h (gdb_id_to_thread): Delete, unused.
13920
139212014-01-22  Doug Evans  <dje@google.com>
13922
13923	* configure.ac (AC_CHECK_FUNCS): Add test for gettimeofday.
13924	* configure: Regenerate.
13925	* config.in: Regenerate.
13926	* Makefile.in (SFILES): Add debug.c.
13927	(OBS): Add debug.o.
13928	* debug.c: New file.
13929	* debug.h: New file.
13930	* linux-aarch64-low.c (*): Update all debugging printfs to use
13931	debug_printf instead of fprintf.
13932	* linux-arm-low.c (*): Ditto.
13933	* linux-cris-low.c (*): Ditto.
13934	* linux-crisv32-low.c (*): Ditto.
13935	* linux-m32r-low.c (*): Ditto.
13936	* linux-sparc-low.c (*): Ditto.
13937	* linux-x86.c (*): Ditto.
13938	* linux-low.c (*): Ditto.
13939	(linux_wait_1): Add calls to debug_enter, debug_exit.
13940	(linux_wait): Remove redundant debugging printf.
13941	(stop_all_lwps): Add calls to debug_enter, debug_exit.
13942	(linux_resume, unstop_all_lwps): Ditto.
13943	* mem-break.c (*): Update all debugging printfs to use
13944	debug_printf instead of fprintf.
13945	* remote-utils.c (*): Ditto.
13946	* thread-db.c (*): Ditto.
13947	* server.c #include <ctype.h>, "gdb_vecs.h".
13948	(debug_threads): Moved to debug.c.
13949	(*): Update all debugging printfs to use debug_printf instead of
13950	fprintf.
13951	(start_inferior): Replace call to fflush with call to debug_flush.
13952	(monitor_show_help): Mention set debug-format.
13953	(parse_debug_format_options): New function.
13954	(handle_monitor_command): Handle "monitor set debug-format".
13955	(gdbserver_usage): Mention --debug-format.
13956	(main): Parse --debug-format.
13957	* server.h (debug_threads): Declaration moved to debug.h.
13958	#include "debug.h".
13959	* tracepoint.c (trace_debug_1) [!IN_PROCESS_AGENT]: Add version of
13960	trace_debug_1 that uses debug_printf.
13961	(tracepoint_look_up_symbols): Update all debugging printfs to use
13962	debug_printf instead of fprintf.
13963
139642014-01-20  Baruch Siach  <baruch@tkos.co.il>
13965
13966	* linux-xtensa-low.c: Include asm/ptrace.h instead of
13967	sys/ptrace.h.
13968
139692014-01-17  Pedro Alves  <palves@redhat.com>
13970
13971	PR build/16445
13972	* linux-x86-low.c: Don't include elf/common.h if ELFMAG0 is
13973	defined after including gdb_proc_service.h.
13974
139752014-01-16  Doug Evans  <dje@google.com>
13976
13977	* dll.c (UNSPECIFIED_CORE_ADDR): New macro.
13978	(match_dll): Use it.
13979
139802014-01-16  Markus Metzger  <markus.t.metzger@intel.com>
13981
13982	* target.h (target_ops) <read_btrace>: Change parameters and
13983	return type to allow error reporting.
13984	* server.c (handle_qxfer_btrace): Support delta reads.  Pass
13985	trace reading errors on.
13986	* linux-low.c (linux_low_read_btrace): Pass trace reading
13987	errors on.
13988	(linux_low_disable_btrace): New.
13989
139902014-01-15  Doug Evans  <dje@google.com>
13991
13992	* inferiors.c (thread_id_to_gdb_id): Delete.
13993	* inferiors.h (thread_id_to_gdb_id): Delete.
13994
139952014-01-13  Eli Zaretskii  <eliz@gnu.org>
13996
13997	* Makefile.in (INCLUDE_CFLAGS): Remove trailing slash from
13998	"-I$(srcdir)/../".  Fixes MinGW compilation errors with old GCC
13999	versions.
14000
140012014-01-08  Pedro Alves  <palves@redhat.com>
14002
14003	* server.c (handle_status): Don't discard previous queued stop
14004	replies or thread's pending status here.
14005	(main) <disconnection>: Do it here instead.
14006
140072014-01-08  Pedro Alves  <palves@redhat.com>
14008
14009	* gdbthread.h (struct thread_info) <status_pending_p>: New field.
14010	* server.c (visit_actioned_threads, handle_pending_status): New
14011	function.
14012	(handle_v_cont): Factor out parts to ...
14013	(resume): ... this new function.  If in all-stop, and a thread
14014	being resumed has a pending status, report it without actually
14015	resuming.
14016	(myresume): Adjust to use the new 'resume' function.
14017	(clear_pending_status_callback, set_pending_status_callback)
14018	(find_status_pending_thread_callback): New functions.
14019	(handle_status): Handle the case of multiple threads having
14020	interesting statuses to report.  Report threads' real last signal
14021	instead of always reporting GDB_SIGNAL_TRAP.  Look for a thread
14022	with an interesting thread to report the status for, instead of
14023	always reporting the status of the first thread.
14024
140252014-01-01  Joel Brobecker  <brobecker@adacore.com>
14026
14027	* gdbserver.c (gdbserver_version): Set copyright year to 2014.
14028	* gdbreplay.c (gdbreplay_version): Likewise.
14029
140302013-12-18  Yufeng Zhang  <yufeng.zhang@arm.com>
14031
14032	* linux-aarch64-low.c (aarch64_linux_set_debug_regs): Set
14033	iov.iov_len with the real length in use.
14034
140352013-12-13  Joel Brobecker  <brobecker@adacore.com>
14036
14037	* Makefile.in (safe-ctype.o, lbasename.o): New rules.
14038	* configure.srv: Add safe-ctype.o and lbasename.o to srv_tgtobj
14039	for all targets that use win32-low.c.
14040	* win32-low.c (win32_ensure_ntdll_loaded): New function.
14041	(do_initial_child_stuff): Add call to win32_ensure_ntdll_loaded.
14042
140432013-12-13  Pedro Alves  <palves@redhat.com>
14044
14045	* target.c (mywait): Set OURSTATUS->KIND to TARGET_WAITKIND_STOPPED
14046	if equal to TARGET_WAITKIND_LOADED.
14047	* win32-low.c (cached_status): New static global.
14048	(win32_wait): Add declaration.
14049	(do_initial_child_stuff): Flush all initial pending debug events
14050	up to the initial breakpoint.
14051	(win32_wait): If CACHED_STATUS was set, return that instead
14052	of doing a real wait.  Remove the code resuming the execution
14053	of the inferior after receiving a TARGET_WAITKIND_LOADED event
14054	during the initial phase.  Also remove the code changing
14055	OURSTATUS->KIND from TARGET_WAITKIND_LOADED to
14056	TARGET_WAITKIND_STOPPED.
14057
140582013-12-11  Yao Qi  <yao@codesourcery.com>
14059
14060	* notif.c (handle_notif_ack): Return 0 if no notification
14061	matches.
14062
140632013-11-20  Doug Evans  <dje@google.com>
14064
14065	* linux-low.c (linux_set_resume_request): Fix comment.
14066
140672013-11-20  Doug Evans  <dje@google.com>
14068
14069	* linux-low.c (resume_status_pending_p): Tweak comment.
14070
140712013-11-20  Walfred Tedeschi  <walfred.tedeschi@intel.com>
14072
14073	* Makefile.in: Add i386-mpx.c, i386-mpx-linux.c, amd64-mpx.c,
14074	amd64-mpx-linux.c, x32-mpx.c and x32-mpx-linux.c generation.
14075	* configure.srv (srv_i386_regobj): Add i386-mpx.o.
14076	(srv_i386_linux_regobj): Add i386-mpx-linux.o.
14077	(srv_amd64_regobj): Add amd64-mpx.o.
14078	(srv_amd64_linux_regobj): Add amd64-mpx-linux.o.
14079	(srv_i386_32bit_xmlfiles): Add i386/32bit-mpx.xml.
14080	(srv_i386_64bit_xmlfiles): Add i386/64bit-mpx.xml.
14081	* i387-fp.c (num_pl_bnd_register) Added constant.
14082	(num_pl_bnd_cfg_registers) Added constant.
14083	(struct i387_xsave) Added reserved area and MPX fields.
14084	(i387_cache_to_xsave, i387_xsave_to_cache) Add MPX.
14085	* linux-x86-low.c (init_registers_i386_mpx_linux): Declare new
14086	function.
14087	(tdesc_i386_mpx_linux): Add MPX amd64 target.
14088	(init_registers_amd64_mpx_linux): Declare new function.
14089	(tdesc_amd64_mpx_linux): Add MPX amd64 target.
14090	(x86_64_regmap): Add MPX registers.
14091	(x86_linux_read_description): Add MPX case.
14092	(initialize_low_arch): Initialize MPX targets.
14093
140942013-11-18  Tom Tromey  <tromey@redhat.com>
14095
14096	* configure: Rebuild.
14097	* configure.ac: Don't check for stdlib.h.
14098	* gdbreplay.c: Unconditionally include stdlib.h.
14099
141002013-11-18  Tom Tromey  <tromey@redhat.com>
14101
14102	* config.in: Rebuild.
14103	* configure: Rebuild.
14104	* configure.ac: Don't use AC_HEADER_DIRENT.
14105
141062013-11-18  Tom Tromey  <tromey@redhat.com>
14107
14108	* server.h: Don't check HAVE_STRING_H.
14109	* gdbreplay.c: Don't check HAVE_STRING_H.
14110	* configure: Rebuild.
14111
141122013-11-18  Tom Tromey  <tromey@redhat.com>
14113
14114	* Makefile.in (gdbreplay$(EXEEXT)): Depend on and link against
14115	LIBGNU.
14116
141172013-11-08  Tom Tromey  <tromey@redhat.com>
14118
14119	* configure, config.in: Rebuild.
14120	* configure.ac: Remove unused configury.
14121
141222013-11-08  Tom Tromey  <tromey@redhat.com>
14123
14124	* acinclude.m4: Include common.m4, codeset.m4.
14125	* configure, config.in: Rebuild.
14126	* configure.ac: Use GDB_AC_COMMON.
14127
141282013-11-06  Andreas Arnez  <arnez@linux.vnet.ibm.com>
14129
14130	* linux-s390-low.c (HWCAP_S390_TE): New define.
14131	(s390_arch_setup): Consider the TE field in the HWCAP for
14132	determining 'have_regset_tdb'.
14133
141342013-10-16  Sergio Durigan Junior  <sergiodj@redhat.com>
14135
14136	PR gdb/16014
14137	* tracepoint.c (download_tracepoint_1): Remove unnecessary double
14138	call to sizeof.
14139
141402013-10-02  Pedro Alves  <palves@redhat.com>
14141
14142	* server.c (process_serial_event): Don't output "GDBserver
14143	exiting" if GDB is connected through stdio.
14144	* target.c (mywait): Likewise, be silent if GDB is connected
14145	through stdio.
14146
141472013-10-01  Joel Brobecker  <brobecker@adacore.com>
14148
14149	* lynx-low.c (lynx_add_threads_after_attach): New function.
14150	(lynx_attach): Remove call to add_thread.  Add call to
14151	lynx_add_threads_after_attach instead.
14152
141532013-09-28  Mike Frysinger  <vapier@gentoo.org>
14154
14155	* configure.ac (AC_CHECK_HEADERS): Add sys/syscall.h
14156	* config.in, configure: Regenerated.
14157
141582013-09-18  Yao Qi  <yao@codesourcery.com>
14159
14160	PR server/15959
14161	* server.c (start_inferior): Clear 'resume_info'.
14162
141632013-09-16  Jiong Wang  <jiwang@tilera.com>
14164
14165	* linux-tile-low.c (tile_regsets): Modify the size field to 64-bit
14166	for each register.
14167
141682013-09-16  Jiong Wang  <jiwang@tilera.com>
14169
14170	* configure.srv <tilegx*-*-linux*>: Remove linux-osdata.o from and add
14171	linux-tile-low.o to srv_tgtobj.
14172
141732013-09-16  Will Newton  <will.newton@linaro.org>
14174
14175	* linux-aarch64-low.c (aarch64_linux_set_debug_regs): Zero
14176	out regs.
14177
141782013-09-06  Pedro Alves  <palves@redhat.com>
14179
14180	* Makefile.in (gdb_proc_service_h, regdef_h, regcache_h)
14181	(signals_def, signals_h, ptid_h, ax_h, agent_h, linux_btrace_h)
14182	(linux_osdata_h, vec_h, gdb_vecs_h, host_defs_h, libiberty_h)
14183	(server_h, gdbthread_h, linux_low_h, linux_ptrace_h)
14184	(gdb_thread_db_h, linux_procfs_h, lynx_low_h, nto_low_h)
14185	(mips_linux_watch_h, i386_low_h, win32_low_h): Delete.
14186
141872013-09-06  Pedro Alves  <palves@redhat.com>
14188
14189	* Makefile.in (linux-btrace.o, mips-linux-watch.o): Remove
14190	explicit header dependencies and use $COMPILE/$POSTCOMPILE.
14191
141922013-09-06  Pedro Alves  <palves@redhat.com>
14193
14194	* linux-amd64-ipa.c: Include tracepoint.h.
14195	* linux-i386-ipa.c: Include tracepoint.h.
14196
141972013-09-06  Ricard Wanderlof  <ricardw@axis.com>
14198
14199	* linux-crisv32-low.c (PTRACE_GET_THREAD_AREA): New macro.
14200	(ps_get_thread_area): New function.
14201
142022013-09-06  Ricard Wanderlof  <ricardw@axis.com>
14203
14204	* linux-crisv32-low.c (elf_gregset_t): Delete typedef.
14205	(initialize_low_arch): Call init_registers_crisv32 rather than
14206	init_register_crisv32.
14207
142082013-09-05  Pedro Alves  <palves@redhat.com>
14209
14210	* server.h (handle_vFile, hostio_last_error_from_errno): Move
14211	to ...
14212	* hostio.h: ... this new file.
14213	* hostio.c, server.c, linux-low.c, nto-low.c, spu-low,
14214	win32-low.c: Include hostio.h.
14215
142162013-09-05  Pedro Alves  <palves@redhat.com>
14217
14218	* server.h (gdb_client_data, handler_func, callback_handler_func)
14219	(delete_file_handler, add_file_handler, append_callback_event)
14220	(delete_callback_event, start_event_loop, initialize_event_loop):
14221	Move to event-loop.h and include it.
14222	* event-loop.h: New file.
14223
142242013-09-05  Pedro Alves  <palves@redhat.com>
14225
14226	* dll.c, inferiors.c, remote-utils.c, server.c: Include "dll.h".
14227	* server.h (struct dll_info, all_dlls, dlls_changed, clear_dlls)
14228	(loaded_dll, unloaded_dll): Move to ...
14229	* dll.h: ... this new file.
14230	* inferiors.c, remote-utils.c, win32-low.c: Include "dll.h".
14231
142322013-09-05  Pedro Alves  <palves@redhat.com>
14233
14234	* server.h (current_process, get_thread_process, all_processes)
14235	(add_inferior_to_list, for_each_inferior, current_inferior)
14236	(remove_inferior, add_process, remove_process, find_process_pid)
14237	(have_started_inferiors_p, have_attached_inferiors_p)
14238	(thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id)
14239	(clear_inferiors, find_inferior, find_inferior_id)
14240	(inferior_target_data, set_inferior_target_data)
14241	(inferior_regcache_data, set_inferior_regcache_data): Move to
14242	inferiors.h, and include it.
14243	* inferiors.h: New file.
14244
142452013-09-05  Pedro Alves  <palves@redhat.com>
14246
14247	* server.h (struct emit_ops, current_insn_ptr, emit_error):
14248	Move ...
14249	* ax.h: ... here.
14250
142512013-09-05  Pedro Alves  <palves@redhat.com>
14252
14253	* ax.c, linux-low.c, linux-x86-low.c, server.c: Include
14254	tracepoint.h.
14255	* server.h (IPA_BUFSIZ, initialize_tracepoint, tracing)
14256	(disconnected_tracing, tracepoint_look_up_symbols, stop_tracing
14257	(handle_tracepoint_general_set, handle_tracepoint_query)
14258	(tracepoint_finished_step, tracepoint_was_hit)
14259	(release_while_stepping_state_list, current_traceframe)
14260	(in_readonly_region, traceframe_read_mem)
14261	(fetch_traceframe_registers, traceframe_read_sdata)
14262	(traceframe_read_info, struct fast_tpoint_collect_status)
14263	(fast_tracepoint_collecting, force_unlock_trace_buffer)
14264	(handle_tracepoit_bkpts, initialize_low_tracepoint)
14265	(supply_fast_tracepoint_registers)
14266	(supply_static_tracepoint_registers, set_trampoline_buffer_space)
14267	(ipa_tdesc, claim_trampoline_space)
14268	(have_fast_tracepoint_trampoline_buffer, gdb_agent_about_to_close)
14269	(agent_mem_read, agent_get_trace_state_variable_value)
14270	(agent_set_trace_state_variable_value, agent_tsv_read)
14271	(agent_mem_read_string, get_raw_reg_func_addr)
14272	(get_get_tsv_func_addr, get_set_tsv_func_addr): Move to ...
14273	* tracepoint.h: ... this new file.
14274
142752013-09-05  Pedro Alves  <palves@redhat.com>
14276
14277	* server.h (perror_with_name, error, fatal, warning, paddress)
14278	(pulongest, plongest, phex_nz, pfildes): Move to utils.h, and
14279	include it.
14280	* utils.h: New file.
14281
142822013-09-05  Pedro Alves  <palves@redhat.com>
14283
14284	* server.h (remote_debug, noack_mode, transport_is_reliable)
14285	(gdb_connected, STDIO_CONNECTION_NAME, remote_connection_is_stdio)
14286	(read_ptid, write_ptid, putpkt, putpkt_binary, putpkt_notif)
14287	(getpkt, remote_prepare, remote_open, remote_close, write_ok)
14288	(write_enn, initialize_async_io, enable_async_io)
14289	(disable_async_io, check_remote_input_interrupt_request)
14290	(convert_ascii_to_int, convert_int_to_ascii, new_thread_notify)
14291	(dead_thread_notify, prepare_resume_reply)
14292	(decode_address_to_semicolon, decode_address, decode_m_packet)
14293	(decode_M_packet, decode_X_packet, decode_xfer_write)
14294	(decode_search_memory_packet, unhexify, hexify)
14295	(remote_escape_output, unpack_varlen_hex, clear_symbol_cache)
14296	(look_up_one_symbol, relocate_instruction)
14297	(monitor_output): Move to remote-utils.h, and include it.
14298	* remote-utils.h: New file.
14299
143002013-09-05  Pedro Alves  <palves@redhat.com>
14301
14302	* server.h (_): Delete.
14303
143042013-09-02  Pedro Alves  <palves@redhat.com>
14305
14306	* tracepoint.c (TRACEFRAME_EOB_MARKER_SIZE): New macro.
14307	(init_trace_buffer): Ensure at least TRACEFRAME_EOB_MARKER_SIZE is
14308	allocated.
14309	(trace_buffer_alloc): Use TRACEFRAME_EOB_MARKER_SIZE.
14310
143112013-09-02  Pierre Muller  <muller@sourceware.org>
14312
14313	* win32-low.c (child_xfer_memory): Check if ReadProcessMemory
14314	or WriteProcessMemory complete successfully and handle
14315	ERROR_PARTIAL_COPY error.
14316
143172013-09-02  Pedro Alves  <palves@redhat.com>
14318
14319	* server.c (gdb_read_memory): Return -1 on traceframe memory read
14320	error instead of EIO.
14321
143222013-08-28  Jan Kratochvil  <jan.kratochvil@redhat.com>
14323
14324	PR server/15604
14325	* linux-low.c: Include filestuff.h.
14326	(linux_create_inferior) <pid == 0>: Call close_most_fds.
14327	* lynx-low.c: Include filestuff.h.
14328	(lynx_create_inferior) <pid == 0>: Call close_most_fds.
14329	* server.c: Include filestuff.h.
14330	(main): Call notice_open_fds.
14331	* spu-low.c: Include filestuff.h.
14332	(spu_create_inferior) <pid == 0>: Call close_most_fds.
14333
143342013-08-22  Luis Machado  <lgustavo@codesourcery.com>
14335
14336	* Makefile.in: Explain why ../target and ../nat are not
14337	listed as include file search paths.
14338	(linux-waitpid.o): New object file rule.
14339	* configure.srv (srv_native_linux_obj): New variable.
14340	Replace all occurrences of linux native object files with
14341	$srv_native_linux_obj.
14342	* linux-low.c: Include nat/linux-nat.h and nat/linux-waitpid.h.
14343	(HAS_NOMMU): Move defining logic to common/linux-ptrace.c.
14344	(linux_enable_event_reporting): Remove declaration.
14345	(my_waitpid): Moved to common/linux-waitpid.c.
14346	(linux_wait_for_event): Pass ptid when calling
14347	linux_enable_event_reporting.
14348	(linux_supports_tracefork_flag): Remove.
14349	(linux_enable_event_reporting): Likewise.
14350	(linux_tracefork_grandchild): Remove.
14351	(STACK_SIZE): Moved to common/linux-ptrace.c.
14352	(linux_tracefork_child): Remove.
14353	(linux_test_for_tracefork): Remove.
14354	(linux_look_up_symbols): Call linux_supports_traceclone.
14355	(initialize_low): Remove call to linux_test_for_tracefork.
14356	* linux-low.h (PTRACE_TYPE_ARG3): Move to
14357	common/linux-ptrace.h.
14358	(PTRACE_TYPE_ARG4): Likewise.
14359	Include linux-ptrace.h.
14360
143612013-08-21  Pedro Alves  <palves@redhat.com>
14362
14363	* config.in: Renegerate.
14364
143652013-08-19  Luis Machado  <lgustavo@codesourcery.com>
14366
14367	* Makefile.in (INCLUDE_CFLAGS): Include -I$(srcdir)/../.
14368	(SFILES): Remove $(srcdir)/common/target-common.c and
14369	add $(srcdir)/target/waitstatus.c.
14370	(OBS): Remove target-common.o and add waitstatus.o.
14371	(server_h): Remove $(srcdir)/../common/target-common.h and
14372	add $(srcdir)/../target/resume.h, $(srcdir)/../target/wait.h
14373	and $(srcdir)/../target/waitstatus.h.
14374	(target-common.o): Remove.
14375	(waitstatus.o): New target object file.
14376	* target.h: Do not include target-common.h and
14377	include target/resume.h, target/wait.h and
14378	target/waitstatus.h.
14379
143802013-08-13  Luis Machado  <lgustavo@codesourcery.com>
14381
14382	* linux-arm-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
14383	to PTRACE_TYPE_ARG3.
14384	* linux-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
14385	to PTRACE_TYPE_ARG3 and PTRACE_ARG4_TYPE to
14386	PTRACE_TYPE_ARG4.
14387	* linux-low.h (PTRACE_ARG3_TYPE): Rename to PTRACE_TYPE_ARG3.
14388	(PTRACE_ARG4_TYPE): Rename to PTRACE_TYPE_ARG4.
14389
143902013-07-27  Jie Zhang  <jie@codesourcery.com>
14391	    Daniel Jacobowitz  <dan@codesourcery.com>
14392	    Yao Qi  <yao@codesourcery.com>
14393
14394	* Makefile.in (SFILES): Add common/mips-linux-watch.c.
14395	(mips-linux-watch.o): New rule.
14396	(mips_linux_watch_h): New variable.
14397	* configure.srv <mips*-*-linux*>: Add mips-linux-watch.o to
14398	srv_tgtobj.
14399	* linux-mips-low.c: Include mips-linux-watch.h.
14400	(struct arch_process_info, struct arch_lwp_info): New.
14401	(update_watch_registers_callback): New function.
14402	(mips_linux_new_process, mips_linux_new_thread) New functions.
14403	(mips_linux_prepare_to_resume, mips_insert_point): New
14404	functions.
14405	(mips_remove_point, mips_stopped_by_watchpoint): New
14406	functions.
14407	(rsp_bp_type_to_target_hw_bp_type): New function.
14408	(mips_stopped_data_address): New function.
14409	(the_low_target): Add watchpoint support functions.
14410
144112013-07-27  Yao Qi  <yao@codesourcery.com>
14412
14413	* i386-low.c: Include break-common.h.
14414	(enum target_hw_bp_type): Remove.
14415
144162013-07-24  Luis Machado  <lgustavo@codesourcery.com>
14417
14418	* Makefile.in (SFILES): /common/target-common.c.
14419	(OBS): Add target-common.o.
14420	(server_h): Add $(srcdir)/../common/target-common.h.
14421	(target-common.o): New target.
14422	* server.c (queue_stop_reply_callback): Free
14423	status string after use.
14424	* target.c (target_waitstatus_to_string): Remove.
14425	* target.h: Include target-common.h.
14426	(resume_kind): Likewise.
14427	(target_waitkind): Likewise.
14428	(target_waitstatus): Likewise.
14429	(TARGET_WNOHANG): Likewise.
14430
144312013-07-04  Yao Qi  <yao@codesourcery.com>
14432
14433	* Makefile.in (host_alias): Use @host_noncanonical@.
14434	(target_alias): Use @target_noncanonical@.
14435	* configure.ac: Use ACX_NONCANONICAL_TARGET and
14436	ACX_NONCANONICAL_HOST.
14437	* configure: Regenerated.
14438
14439	Revert:
14440	2013-06-28  Mircea Gherzan  <mircea.gherzan@intel.com>
14441
14442	* configure.ac (version_host, version_target): Set and AC_SUBST them.
14443	* configure: Rebuild.
14444	* Makefile.in (version_host, version_target): Get from configure.
14445	(version.c): Use $(version_host) and $(version_target).
14446
144472013-07-03  Pedro Alves  <palves@redhat.com>
14448
14449	* Makefile.in (config.status): Depend on development.sh.
14450	* acinclude.m4: Include libmcheck.m4.
14451	* configure: Regenerate.
14452
144532013-07-02  Mircea Gherzan  <mircea.gherzan@intel.com>
14454
14455	* win32-low.c (winapi_DebugActiveProcessStop): Move the WINAPI
14456	attribute inside the parentheses.
14457	(winapi_DebugSetProcessKillOnExit): Ditto.
14458	(winapi_DebugBreakProcess): Ditto.
14459	(winapi_GenerateConsoleCtrlEvent): Ditto.
14460
144612013-07-02  Mircea Gherzan  <mircea.gherzan@intel.com>
14462
14463	* notif.h (notif_event): Add a dummy member to avoid compiler
14464	errors.
14465
144662013-07-01  Pedro Alves  <palves@redhat.com>
14467
14468	* hostio.c (HOSTIO_PATH_MAX): Define.
14469	(require_filename, handle_open, handle_unlink, handle_readlink):
14470	Use it.
14471
144722013-07-01  Pedro Alves  <palves@redhat.com>
14473
14474	* server.h: Include "pathmax.h".
14475	* linux-low.c: Don't include sys/param.h.
14476	(linux_pid_exe_is_elf_64_file): Use PATH_MAX instead of
14477	MAXPATHLEN.
14478	* win32-low.c: Don't include sys/param.h.
14479	(win32_create_inferior): Use PATH_MAX instead of MAXPATHLEN.
14480
144812013-07-01  Pedro Alves  <palves@redhat.com>
14482
14483	* event-loop.c: Don't check HAVE_UNISTD_H before including
14484	<unistd.h>.
14485	* gdbreplay.c: Likewise.
14486	* remote-utils.c: Likewise.
14487	* server.c: Likewise.
14488	* configure.ac: Don't check for unistd.h.
14489	* configure: Regenerate.
14490
144912013-06-28  Tom Tromey  <tromey@redhat.com>
14492
14493	* Makefile.in (version.c): Use version.in, not
14494	common/version.in.
14495
144962013-06-28  Mircea Gherzan  <mircea.gherzan@intel.com>
14497
14498	* configure.ac (version_host, version_target): Set and AC_SUBST them.
14499	* configure: Rebuild.
14500	* Makefile.in (version_host, version_target): Get from configure.
14501	(version.c): Use $(version_host) and $(version_target).
14502
145032013-06-10  Dmitry Kozlov <ddk@codesourcery.com>
14504
14505	Fix trace-status to output user name without trailing colon.
14506	* tracepoint.c (cmd_qtstatus): Remove unnecessary colon from user name.
14507
145082013-06-10  Dmitry Kozlov <ddk@codesourcery.com>
14509
14510	Fix trace-status to output proper start-time and stop-time.
14511	* tracepoint.c (cmd_qtstatus): Modify trace-status output to
14512	output start time and stop time in hex as gdb expects.
14513
145142013-06-26  Pedro Alves  <pedro@codesourcery.com>
14515
14516	* tracepoint.c (build_traceframe_info_xml): Output trace state
14517	variables present in the trace buffer.
14518
145192013-06-24  Tom Tromey  <tromey@redhat.com>
14520
14521	* Makefile.in (version.c): Use bfd/version.h, common/version.in,
14522	create-version.sh.
14523	(version.o): Remove.
14524	* gdbreplay.c: Include version.h.
14525	(version, host_name): Don't declare.
14526	* server.h: Include version.h.
14527	(version, host_name): Don't declare.
14528
145292013-06-12  Pedro Alves  <palves@redhat.com>
14530
14531	* linux-x86-low.c (linux_is_elf64): Delete global.
14532	(x86_siginfo_fixup): Replace reference to `linux_is_elf64' global
14533	with local linux_pid_exe_is_elf_64_file use.
14534
145352013-06-11  Pedro Alves  <palves@redhat.com>
14536
14537	* linux-low.c (regset_disabled, disable_regset): New functions.
14538	(regsets_fetch_inferior_registers)
14539	(regsets_store_inferior_registers): Use them.
14540	(initialize_regsets_info); Don't allocate the disabled_regsets
14541	array here.
14542	* linux-low.h (struct regsets_info) <disabled_regsets>: Extend
14543	comment.
14544
145452013-06-11  Pedro Alves  <palves@redhat.com>
14546
14547	* linux-low.c (initialize_regsets_info): Use xcalloc instead of
14548	xmalloc.
14549
145502013-06-11  Pedro Alves  <palves@redhat.com>
14551
14552	* linux-x86-low.c (initialize_low_arch): Call
14553	init_registers_x32_avx_linux.
14554
145552013-06-09  Jan Kratochvil  <jan.kratochvil@redhat.com>
14556
14557	Fix compatibility with Android Bionic.
14558	* linux-low.c (linux_qxfer_libraries_svr4): Ignore first entry even if
14559	it is not empty.
14560
145612013-06-07  Pedro Alves  <palves@redhat.com>
14562
14563	PR server/14823
14564	* Makefile.in (OBS): Add tdesc.o.
14565	(IPA_OBJS): Add tdesc-ipa.o.
14566	(tdesc-ipa.o): New rule.
14567	* ax.c (gdb_eval_agent_expr): Adjust register_size call to new
14568	interface.
14569	* linux-low.c (new_inferior): Delete.
14570	(disabled_regsets, num_regsets): Delete.
14571	(linux_add_process): Adjust to set the new per-process
14572	new_inferior flag.
14573	(linux_detach_one_lwp): Adjust to call regcache_invalidate_thread.
14574	(linux_wait_for_lwp): Adjust.  Only call arch_setup if the event
14575	was a stop.  When calling arch_setup, switch the current inferior
14576	to the thread that got an event.
14577	(linux_resume_one_lwp): Adjust to call regcache_invalidate_thread.
14578	(regsets_fetch_inferior_registers)
14579	(regsets_store_inferior_registers): New regsets_info parameter.
14580	Adjust to use it.
14581	(linux_register_in_regsets): New regs_info parameter.  Adjust to
14582	use it.
14583	(register_addr, fetch_register, store_register): New usrregs_info
14584	parameter.  Adjust to use it.
14585	(usr_fetch_inferior_registers, usr_store_inferior_registers): New
14586	parameter regs_info.  Adjust to use it.
14587	(linux_fetch_registers): Get the current inferior's regs_info, and
14588	adjust to use it.
14589	(linux_store_registers): Ditto.
14590	[HAVE_LINUX_REGSETS] (initialize_regsets_info): New.
14591	(initialize_low): Don't initialize the target_regsets here.  Call
14592	initialize_low_arch.
14593	* linux-low.h (target_regsets): Delete declaration.
14594	(struct regsets_info): New.
14595	(struct usrregs_info): New.
14596	(struct regs_info): New.
14597	(struct process_info_private) <new_inferior>: New field.
14598	(struct linux_target_ops): Delete the num_regs, regmap, and
14599	regset_bitmap fields.  New field regs_info.
14600	[HAVE_LINUX_REGSETS] (initialize_regsets_info): Declare.
14601	* i387-fp.c (num_xmm_registers): Delete.
14602	(i387_cache_to_fsave, i387_fsave_to_cache): Adjust find_regno
14603	calls to new interface.
14604	(i387_cache_to_fxsave, i387_cache_to_xsave, i387_fxsave_to_cache)
14605	(i387_xsave_to_cache): Adjust find_regno calls to new interface.
14606	Infer the number of xmm registers from the regcache's target
14607	description.
14608	* i387-fp.h (num_xmm_registers): Delete.
14609	* inferiors.c (add_thread): Don't install the thread's regcache
14610	here.
14611	* proc-service.c (gregset_info): Fetch the current inferior's
14612	regs_info.  Adjust to use it.
14613	* regcache.c: Include tdesc.h.
14614	(register_bytes, reg_defs, num_registers)
14615	(gdbserver_expedite_regs): Delete.
14616	(get_thread_regcache): If the thread doesn't have a regcache yet,
14617	create one, instead of aborting gdbserver.
14618	(regcache_invalidate_one): Rename to ...
14619	(regcache_invalidate_thread): ... this.
14620	(regcache_invalidate_one): New.
14621	(regcache_invalidate): Only invalidate registers of the current
14622	process.
14623	(init_register_cache): Add target_desc parameter, and use it.
14624	(new_register_cache): Ditto.  Assert the target description has a
14625	non zero registers_size.
14626	(regcache_cpy): Add assertions.  Adjust.
14627	(realloc_register_cache, set_register_cache): Delete.
14628	(registers_to_string, registers_from_string): Adjust.
14629	(find_register_by_name, find_regno, find_register_by_number)
14630	(register_cache_size): Add target_desc parameter, and use it.
14631	(free_register_cache_thread, free_register_cache_thread_one)
14632	(regcache_release, register_cache_size): New.
14633	(register_size): Add target_desc parameter, and use it.
14634	(register_data, supply_register, supply_register_zeroed)
14635	(supply_regblock, supply_register_by_name, collect_register)
14636	(collect_register_as_string, collect_register_by_name): Adjust.
14637	* regcache.h (struct target_desc): Forward declare.
14638	(struct regcache) <tdesc>: New field.
14639	(init_register_cache, new_register_cache): Add target_desc
14640	parameter.
14641	(regcache_invalidate_thread): Declare.
14642	(regcache_invalidate_one): Delete declaration.
14643	(regcache_release): Declare.
14644	(find_register_by_number, register_cache_size, register_size)
14645	(find_regno): Add target_desc parameter.
14646	(gdbserver_expedite_regs, gdbserver_xmltarget): Delete
14647	declarations.
14648	* remote-utils.c: Include tdesc.h.
14649	(outreg, prepare_resume_reply): Adjust.
14650	* server.c: Include tdesc.h.
14651	(gdbserver_xmltarget): Delete declaration.
14652	(get_features_xml, process_serial_event): Adjust.
14653	* server.h [IN_PROCESS_AGENT] (struct target_desc): Forward
14654	declare.
14655	(struct process_info) <tdesc>: New field.
14656	(ipa_tdesc): Declare.
14657	* tdesc.c: New file.
14658	* tdesc.h: New file.
14659	* tracepoint.c: Include tdesc.h.
14660	[IN_PROCESS_AGENT] (ipa_tdesc): Define.
14661	(get_context_regcache): Adjust to pass ipa_tdesc down.
14662	(do_action_at_tracepoint): Adjust to get the register cache size
14663	from the context regcache's description.
14664	(traceframe_walk_blocks): Adjust to get the register cache size
14665	from the current trace frame's description.
14666	(traceframe_get_pc): Adjust to get current trace frame's
14667	description and pass it down.
14668	(gdb_collect): Adjust to get the register cache size from the
14669	IPA's description.
14670	* linux-amd64-ipa.c (tdesc_amd64_linux): Declare.
14671	(gdbserver_xmltarget): Delete.
14672	(initialize_low_tracepoint): Set the ipa's target description.
14673	* linux-i386-ipa.c (tdesc_i386_linux): Declare.
14674	(initialize_low_tracepoint): Set the ipa's target description.
14675	* linux-x86-low.c: Include tdesc.h.
14676	[__x86_64__] (is_64bit_tdesc): New.
14677	(ps_get_thread_area, x86_get_thread_area): Use it.
14678	(i386_cannot_store_register): Rename to ...
14679	(x86_cannot_store_register): ... this.  Use is_64bit_tdesc.
14680	(i386_cannot_fetch_register): Rename to ...
14681	(x86_cannot_fetch_register): ... this.  Use is_64bit_tdesc.
14682	(x86_fill_gregset, x86_store_gregset): Adjust register_size calls
14683	to new interface.
14684	(target_regsets): Rename to ...
14685	(x86_regsets): ... this.
14686	(x86_get_pc, x86_set_pc): Adjust register_size calls to new
14687	interface.
14688	(x86_siginfo_fixup): Use is_64bit_tdesc.
14689	[__x86_64__] (tdesc_amd64_linux, tdesc_amd64_avx_linux)
14690	(tdesc_x32_avx_linux, tdesc_x32_linux)
14691	(tdesc_i386_linux, tdesc_i386_mmx_linux, tdesc_i386_avx_linux):
14692	Declare.
14693	(x86_linux_update_xmltarget): Delete.
14694	(I386_LINUX_XSAVE_XCR0_OFFSET): Define.
14695	(have_ptrace_getfpxregs, have_ptrace_getregset): New.
14696	(AMD64_LINUX_USER64_CS): New.
14697	(x86_linux_read_description): New, based on
14698	x86_linux_update_xmltarget.
14699	(same_process_callback): New.
14700	(x86_arch_setup_process_callback): New.
14701	(x86_linux_update_xmltarget): New.
14702	(x86_regsets_info): New.
14703	(amd64_linux_regs_info): New.
14704	(i386_linux_usrregs_info): New.
14705	(i386_linux_regs_info): New.
14706	(x86_linux_regs_info): New.
14707	(x86_arch_setup): Reimplement.
14708	(x86_install_fast_tracepoint_jump_pad): Use is_64bit_tdesc.
14709	(x86_emit_ops): Ditto.
14710	(the_low_target): Adjust.  Install x86_linux_regs_info,
14711	x86_cannot_fetch_register, and x86_cannot_store_register.
14712	(initialize_low_arch): New.
14713	* linux-ia64-low.c (tdesc_ia64): Declare.
14714	(ia64_fetch_register): Adjust.
14715	(ia64_usrregs_info, regs_info): New globals.
14716	(ia64_regs_info): New function.
14717	(the_low_target): Adjust.
14718	(initialize_low_arch): New function.
14719	* linux-sparc-low.c (tdesc_sparc64): Declare.
14720	(sparc_fill_gregset_to_stack, sparc_store_gregset_from_stack):
14721	Adjust.
14722	(sparc_arch_setup): New function.
14723	(sparc_regsets_info, sparc_usrregs_info, regs_info): New globals.
14724	(the_low_target): Adjust.
14725	(initialize_low_arch): New function.
14726	* linux-ppc-low.c (tdesc_powerpc_32l, tdesc_powerpc_altivec32l)
14727	(tdesc_powerpc_cell32l, tdesc_powerpc_vsx32l)
14728	(tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_altivec32l)
14729	(tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_e500l)
14730	(tdesc_powerpc_64l, tdesc_powerpc_altivec64l)
14731	(tdesc_powerpc_cell64l, tdesc_powerpc_vsx64l)
14732	(tdesc_powerpc_isa205_64l, tdesc_powerpc_isa205_altivec64l)
14733	(tdesc_powerpc_isa205_vsx64l): Declare.
14734	(ppc_cannot_store_register, ppc_collect_ptrace_register)
14735	(ppc_supply_ptrace_register, parse_spufs_run, ppc_get_pc)
14736	(ppc_set_pc, ppc_get_hwcap): Adjust.
14737	(ppc_usrregs_info): Forward declare.
14738	(!__powerpc64__) ppc_regmap_adjusted: New global.
14739	(ppc_arch_setup): Adjust to the current process'es target
14740	description.
14741	(ppc_fill_vsxregset, ppc_store_vsxregset, ppc_fill_vrregset)
14742	(ppc_store_vrregset, ppc_fill_evrregset, ppc_store_evrregse)
14743	(ppc_store_evrregset): Adjust.
14744	(target_regsets): Rename to ...
14745	(ppc_regsets): ... this, and make static.
14746	(ppc_usrregs_info, ppc_regsets_info, regs_info): New globals.
14747	(ppc_regs_info): New function.
14748	(the_low_target): Adjust.
14749	(initialize_low_arch): New function.
14750	* linux-s390-low.c (tdesc_s390_linux32, tdesc_s390_linux32v1)
14751	(tdesc_s390_linux32v2, tdesc_s390_linux64, tdesc_s390_linux64v1)
14752	(tdesc_s390_linux64v2, tdesc_s390x_linux64, tdesc_s390x_linux64v1)
14753	(tdesc_s390x_linux64v2): Declare.
14754	(s390_collect_ptrace_register, s390_supply_ptrace_register)
14755	(s390_fill_gregset, s390_store_last_break): Adjust.
14756	(target_regsets): Rename to ...
14757	(s390_regsets): ... this, and make static.
14758	(s390_get_pc, s390_set_pc): Adjust.
14759	(s390_get_hwcap): New target_desc parameter, and use it.
14760	[__s390x__] (have_hwcap_s390_high_gprs): New global.
14761	(s390_arch_setup): Adjust to set the current process'es target
14762	description.  Don't adjust the regmap.
14763	(s390_usrregs_info, s390_regsets_info, regs_info): New globals.
14764	[__s390x__] (s390_usrregs_info_3264, s390_regsets_info_3264)
14765	(regs_info_3264): New globals.
14766	(s390_regs_info): New function.
14767	(the_low_target): Adjust.
14768	(initialize_low_arch): New function.
14769	* linux-mips-low.c (tdesc_mips_linux, tdesc_mips_dsp_linux)
14770	(tdesc_mips64_linux, tdesc_mips64_dsp_linux): Declare.
14771	[__mips64] (init_registers_mips_linux)
14772	(init_registers_mips_dsp_linux): Delete defines.
14773	[__mips64] (tdesc_mips_linux, tdesc_mips_dsp_linux): New defines.
14774	(have_dsp): New global.
14775	(mips_read_description): New, based on mips_arch_setup.
14776	(mips_arch_setup): Reimplement.
14777	(get_usrregs_info): New function.
14778	(mips_cannot_fetch_register, mips_cannot_store_register)
14779	(mips_get_pc, mips_set_pc, mips_fill_gregset, mips_store_gregset)
14780	(mips_fill_fpregset, mips_store_fpregset): Adjust.
14781	(target_regsets): Rename to ...
14782	(mips_regsets): ... this, and make static.
14783	(mips_regsets_info, mips_dsp_usrregs_info, mips_usrregs_info)
14784	(dsp_regs_info, regs_info): New globals.
14785	(mips_regs_info): New function.
14786	(the_low_target): Adjust.
14787	(initialize_low_arch): New function.
14788	* linux-arm-low.c (tdesc_arm, tdesc_arm_with_iwmmxt)
14789	(tdesc_arm_with_vfpv2, tdesc_arm_with_vfpv3, tdesc_arm_with_neon):
14790	Declare.
14791	(arm_fill_vfpregset, arm_store_vfpregset): Adjust.
14792	(arm_read_description): New, with bits factored from
14793	arm_arch_setup.
14794	(arm_arch_setup): Reimplement.
14795	(target_regsets): Rename to ...
14796	(arm_regsets): ... this, and make static.
14797	(arm_regsets_info, arm_usrregs_info, regs_info): New globals.
14798	(arm_regs_info): New function.
14799	(the_low_target): Adjust.
14800	(initialize_low_arch): New function.
14801	* linux-m68k-low.c (tdesc_m68k): Declare.
14802	(target_regsets): Rename to ...
14803	(m68k_regsets): ... this, and make static.
14804	(m68k_regsets_info, m68k_usrregs_info, regs_info): New globals.
14805	(m68k_regs_info): New function.
14806	(m68k_arch_setup): New function.
14807	(the_low_target): Adjust.
14808	(initialize_low_arch): New function.
14809	* linux-sh-low.c (tdesc_sharch): Declare.
14810	(target_regsets): Rename to ...
14811	(sh_regsets): ... this, and make static.
14812	(sh_regsets_info, sh_usrregs_info, regs_info): New globals.
14813	(sh_regs_info, sh_arch_setup): New functions.
14814	(the_low_target): Adjust.
14815	(initialize_low_arch): New function.
14816	* linux-bfin-low.c (tdesc_bfin): Declare.
14817	(bfin_arch_setup): New function.
14818	(bfin_usrregs_info, regs_info): New globals.
14819	(bfin_regs_info): New function.
14820	(the_low_target): Adjust.
14821	(initialize_low_arch): New function.
14822	* linux-cris-low.c (tdesc_cris): Declare.
14823	(cris_arch_setup): New function.
14824	(cris_usrregs_info, regs_info): New globals.
14825	(cris_regs_info): New function.
14826	(the_low_target): Adjust.
14827	(initialize_low_arch): New function.
14828	* linux-cris-low.c (tdesc_crisv32): Declare.
14829	(cris_arch_setup): New function.
14830	(cris_regsets_info, cris_usrregs_info, regs_info): New globals.
14831	(cris_regs_info): New function.
14832	(the_low_target): Adjust.
14833	(initialize_low_arch): New function.
14834	* linux-m32r-low.c (tdesc_m32r): Declare.
14835	(m32r_arch_setup): New function.
14836	(m32r_usrregs_info, regs_info): New globals.
14837	(m32r_regs_info): Adjust.
14838	(initialize_low_arch): New function.
14839	* linux-tic6x-low.c (tdesc_tic6x_c64xp_linux)
14840	(tdesc_tic6x_c64x_linux, tdesc_tic6x_c62x_linux): Declare.
14841	(tic6x_usrregs_info): Forward declare.
14842	(tic6x_read_description): New function, based on ...
14843	(tic6x_arch_setup): ... this.  Reimplement.
14844	(target_regsets): Rename to ...
14845	(tic6x_regsets): ... this, and make static.
14846	(tic6x_regsets_info, tic6x_usrregs_info, regs_info): New globals.
14847	(tic6x_regs_info): New function.
14848	(the_low_target): Adjust.
14849	(initialize_low_arch): New function.
14850	* linux-xtensa-low.c (tdesc_xtensa): Declare.
14851	(xtensa_fill_gregset, xtensa_store_gregset): Adjust.
14852	(target_regsets): Rename to ...
14853	(xtensa_regsets): ... this, and make static.
14854	(xtensa_regsets_info, xtensa_usrregs_info, regs_info): New
14855	globals.
14856	(xtensa_arch_setup, xtensa_regs_info): New functions.
14857	(the_low_target): Adjust.
14858	(initialize_low_arch): New function.
14859	* linux-nios2-low.c (tdesc_nios2_linux): Declare.
14860	(nios2_arch_setup): Set the current process'es tdesc.
14861	(target_regsets): Rename to ...
14862	(nios2_regsets): ... this.
14863	(nios2_regsets_info, nios2_usrregs_info, regs_info): New globals.
14864	(nios2_regs_info): New function.
14865	(the_low_target): Adjust.
14866	(initialize_low_arch): New function.
14867	* linux-aarch64-low.c (tdesc_aarch64): Declare.
14868	(aarch64_arch_setup): Set the current process'es tdesc.
14869	(target_regsets): Rename to ...
14870	(aarch64_regsets): ... this.
14871	(aarch64_regsets_info, aarch64_usrregs_info, regs_info): New globals.
14872	(aarch64_regs_info): New function.
14873	(the_low_target): Adjust.
14874	(initialize_low_arch): New function.
14875	* linux-tile-low.c (tdesc_tilegx, tdesc_tilegx32): Declare
14876	globals.
14877	(target_regsets): Rename to ...
14878	(tile_regsets): ... this.
14879	(tile_regsets_info, tile_usrregs_info, regs_info): New globals.
14880	(tile_regs_info): New function.
14881	(tile_arch_setup): Set the current process'es tdesc.
14882	(the_low_target): Adjust.
14883	(initialize_low_arch): New function.
14884	* spu-low.c (tdesc_spu): Declare.
14885	(spu_create_inferior, spu_attach): Set the new process'es tdesc.
14886	* win32-arm-low.c (tdesc_arm): Declare.
14887	(arm_arch_setup): New function.
14888	(the_low_target): Install arm_arch_setup instead of
14889	init_registers_arm.
14890	* win32-i386-low.c (tdesc_i386, tdesc_amd64): Declare.
14891	(init_windows_x86): Rename to ...
14892	(i386_arch_setup): ... this.  Set `win32_tdesc'.
14893	(the_low_target): Adjust.
14894	* win32-low.c (win32_tdesc): New global.
14895	(child_add_thread): Don't create the thread cache here.
14896	(do_initial_child_stuff): Set the new process'es tdesc.
14897	* win32-low.h (struct target_desc): Forward declare.
14898	(win32_tdesc): Declare.
14899	* lynx-i386-low.c (tdesc_i386): Declare global.
14900	(lynx_i386_arch_setup): Set `lynx_tdesc'.
14901	* lynx-low.c (lynx_tdesc): New global.
14902	(lynx_add_process): Set the new process'es tdesc.
14903	* lynx-low.h (struct target_desc): Forward declare.
14904	(lynx_tdesc): Declare global.
14905	* lynx-ppc-low.c (tdesc_powerpc_32): Declare global.
14906	(lynx_ppc_arch_setup): Set `lynx_tdesc'.
14907	* nto-low.c (nto_tdesc): New global.
14908	(do_attach): Set the new process'es tdesc.
14909	* nto-low.h (struct target_desc): Forward declare.
14910	(nto_tdesc): Declare.
14911	* nto-x86-low.c (tdesc_i386): Declare.
14912	(nto_x86_arch_setup): Set `nto_tdesc'.
14913
149142013-06-04  Gary Benson  <gbenson@redhat.com>
14915
14916	* server.c (handle_query): Add "augmented-libraries-svr4-read+"
14917	to qSupported response when appropriate.
14918	(handle_qxfer_libraries_svr4): Allow qXfer:libraries-svr4:read
14919	with nonzero-length annex.
14920	* linux-low.c (linux_qxfer_libraries_svr4): Parse and handle
14921	arguments supplied in annex.
14922
149232013-05-31  Doug Evans  <dje@google.com>
14924
14925	PR server/15594
14926	* linux-x86-low.c (ps_get_thread_area): Properly extend address to
14927	64 bits in 64-cross-32 environment.
14928
149292013-05-28  Pedro Alves  <palves@redhat.com>
14930
14931	* Makefile.in (clean): Remove reference to aarch64-without-fpu.c.
14932	(aarch64-without-fpu.c): Delete rule.
14933	* configure.srv (aarch64*-*-linux*): Remove references to
14934	aarch64-without-fpu.o and aarch64-without-fpu.xml.
14935	* linux-aarch64-low.c (init_registers_aarch64_without_fpu): Remove
14936	declaration.
14937
149382013-05-24  Pedro Alves  <palves@redhat.com>
14939
14940	* server.c (handle_v_cont) <vCont;r>: Use unpack_varlen_hex
14941	instead of strchr/decode_address.  Error if the range isn't split
14942	with a ','.  Don't assume there's be a ':' in the action.
14943
149442013-05-23  Yao Qi  <yao@codesourcery.com>
14945	    Pedro Alves  <palves@redhat.com>
14946
14947	* linux-low.c (lwp_in_step_range): New function.
14948	(linux_wait_1): If the thread was range stepping and stopped
14949	outside the stepping range, report the stop to GDB.  Otherwise,
14950	continue stepping.  Add range stepping debug output.
14951	(linux_set_resume_request): Copy the step range from the resume
14952	request to the lwp.
14953	(linux_supports_range_stepping): New.
14954	(linux_target_ops) <supports_range_stepping>: Set to
14955	linux_supports_range_stepping.
14956	* linux-low.h (struct linux_target_ops)
14957	<supports_range_stepping>: New field.
14958	(struct lwp_info) <step_range_start, step_range_end>: New fields.
14959	* linux-x86-low.c (x86_supports_range_stepping): New.
14960	(the_low_target) <supports_range_stepping>: Set to
14961	x86_supports_range_stepping.
14962	* server.c (handle_v_cont): Handle 'r' action.
14963	(handle_v_requests): Append ";r" if the target supports range
14964	stepping.
14965	* target.h (struct thread_resume) <step_range_start,
14966	step_range_end>: New fields.
14967	(struct target_ops) <supports_range_stepping>:
14968	New field.
14969	(target_supports_range_stepping): New macro.
14970
149712013-05-17  Joel Brobecker  <brobecker@adacore.com>
14972
14973	* lynx-low.c (lynx_resume): Fix null_ptid/minus_one_ptid
14974	confusion in comment.
14975
149762013-05-17  Joel Brobecker  <brobecker@adacore.com>
14977
14978	* lynx-low.c (struct process_info_private): New type.
14979	(lynx_add_process): New function.
14980	(lynx_create_inferior, lynx_attach): Replace calls to
14981	add_process by calls to lynx_add_process.
14982	(lynx_resume): If PTID is null, then try using
14983	current_process()->private->last_wait_event_ptid.
14984	Add comments.
14985	(lynx_clear_inferiors): Delete.  The contents of that function
14986	has been inlined in lynx_mourn;
14987	(lynx_wait_1): Save the ptid in the process's private data.
14988	(lynx_mourn): Free the process' private data.  Replace call
14989	to lynx_clear_inferiors by call to clear_inferiors.
14990
149912013-05-17  Yao Qi  <yao@codesourcery.com>
14992
14993	* i386-low.c (i386_length_and_rw_bits): Move the comment to
14994	the right place.
14995
149962013-05-16  Luis Machado  <lgustavo@codesourcery.com>
14997
14998	* linux-low.c: Move definition checks upwards for PT_TEXT_ADDR,
14999	PT_DATA_ADDR and PT_TEXT_END_ADDR.  Update comments.
15000	(linux_read_offsets): Remove PT_TEXT_ADDR, PT_DATA_ADDR and
15001	PT_TEXT_END_ADDR guards.  Update comments.
15002	(linux_target_op) <read_offsets>: Conditionally define to
15003	linux_read_offsets if the target is UCLIBC and if it defines
15004	PT_TEXT_ADDR, PT_DATA_ADDR and PT_TEXT_END_ADDR.
15005
150062013-05-06  Sandra Loosemore  <sandra@codesourcery.com>
15007	    Andrew Jenner  <andrew@codesourcery.com>
15008
15009	* Makefile.in (SFILES): Add linux-nios2-low.c.
15010	(clean): Add action to delete nios2-linux.c.
15011	(nios2-linux.c): New rule.
15012	* configure.srv: Add nios2*-*-linux*.
15013	* linux-nios2-low.c: New.
15014
150152013-05-03  Hafiz Abid Qadeer  <abidh@codesourcery.com>
15016
15017	* tracepoint.c (cmd_qtinit): Call 'stop_tracing'.
15018
150192013-04-25  Hui Zhu  <hui@codesourcery.com>
15020
15021	PR gdb/15186
15022	* ax.c (ax_printf): Add fflush.
15023
150242013-04-22  Tom Tromey  <tromey@redhat.com>
15025
15026	* Makefile.in (SFILES): Add filestuff.c.
15027	(OBS): Add filestuff.o.
15028	(filestuff.o): New target.
15029	* config.in, configure: Rebuild.
15030	* configure.ac: Check for fdwalk, pipe2.
15031
150322013-04-17  Pedro Alves  <palves@redhat.com>
15033
15034	* configure.ac (USE_THREAD_DB): Delete variable.
15035	(if test "$srv_linux_thread_db" = "yes"): AC_DEFINE USE_THREAD_DB.
15036	Don't AC_SUBST USE_THREAD_DB.
15037	* Makefile.in (INTERNAL_CFLAGS): Remove @USE_THREAD_DB@.
15038	* config.in, configure: Regenerate.
15039
150402013-04-16  Pedro Alves  <palves@redhat.com>
15041
15042	* linux-low.h (struct lwp_info) <thread_known>: Move under
15043	the USE_THREAD_DB #ifdef.
15044
150452013-04-16  Pedro Alves  <palves@redhat.com>
15046
15047	* Makefile.in (INTERNAL_CFLAGS): Add @USE_THREAD_DB@.
15048	(linux-low.o): Delete rule.
15049	* linux-low.h: Always include "gdb_thread_db.h" instead of
15050	conditionally including thread_db.h.
15051	(struct lwp_info) <th>: Guard with #ifdef USE_THREAD_DB instead of
15052	HAVE_THREAD_DB_H.
15053
150542013-04-07  Jan Kratochvil  <jan.kratochvil@redhat.com>
15055
15056	* Makefile.in (install-only): Fix make install regression.
15057
150582013-04-05  Jan Kratochvil  <jan.kratochvil@redhat.com>
15059
15060	Convert man pages to texinfo, new gdbinit.5 texinfo page.
15061	* Makefile.in (install-only): Remove $(man1dir) and gdbserver.1
15062	installation.
15063	* gdbserver.1: Remove.
15064
150652013-03-22  Pedro Alves  <palves@redhat.com>
15066
15067	* linux-low.c (handle_extended_wait): Don't call
15068	linux_enable_event_reporting.
15069
150702013-03-15  Tony Theodore  <tonyt@logyst.com>
15071
15072	PR build/9098:
15073	* Makefile.in (SHELL): Use @SHELL@.
15074
150752013-03-14  Sergio Durigan Junior  <sergiodj@redhat.com>
15076
15077	* tracepoint.c (cmd_qtv): Initialize `val' with zero, silencing
15078	compiler warning.
15079
150802013-03-13  Joel Brobecker  <brobecker@adacore.com>
15081
15082	* linux-low.c (linux_target_ops) [!HAVE_LINUX_BTRACE]:
15083	Remove extraneous NULL element.
15084
150852013-03-13  Yao Qi  <yao@codesourcery.com>
15086
15087	* tracepoint.c (traceframe_read_tsv): Look for the last matched
15088	'V' block in trace frame.
15089
150902013-03-11  Markus Metzger  <markus.t.metzger@intel.com>
15091
15092	* target.h (struct target_ops): Add btrace ops.
15093	(target_supports_btrace): New macro.
15094	(target_enable_btrace): New macro.
15095	(target_disable_btrace): New macro.
15096	(target_read_btrace): New macro.
15097	* gdbthread.h (struct thread_info): Add btrace field.
15098	* server.c: Include btrace-common.h.
15099	(handle_btrace_general_set): New function.
15100	(handle_btrace_enable): New function.
15101	(handle_btrace_disable): New function.
15102	(handle_general_set): Call handle_btrace_general_set.
15103	(handle_qxfer_btrace): New function.
15104	(struct qxfer qxfer_packets[]): Add btrace entry.
15105	* inferiors.c (remove_thread): Disable btrace.
15106	* linux-low: Include linux-btrace.h.
15107	(linux_low_enable_btrace): New function.
15108	(linux_low_read_btrace): New function.
15109	(linux_target_ops): Add btrace ops.
15110	* configure.srv (i[34567]86-*-linux*): Add linux-btrace.o.
15111	Add srv_linux_btrace=yes.
15112	(x86_64-*-linux*): Add linux-btrace.o.
15113	Add srv_linux_btrace=yes.
15114	* configure.ac: Define HAVE_LINUX_BTRACE.
15115	* config.in: Regenerated.
15116	* configure: Regenerated.
15117
151182013-03-11  Markus Metzger  <markus.t.metzger@intel.com>
15119
15120	* server.c (handle_qxfer): Preserve error message if -3 is
15121	returned.
15122	(qxfer): Document the -3 return value.
15123
151242013-03-11  Markus Metzger  <markus.t.metzger@intel.com>
15125
15126	* Makefile.in (SFILES): Add $(srcdir)/common/linux-btrace.c.
15127	(linux_btrace_h): New variable.
15128	(linux-btrace.o): New rule.
15129
151302013-03-08  Stan Shebs  <stan@codesourcery.com>
15131	    Hafiz Abid Qadeer  <abidh@codesourcery.com>
15132
15133	* tracepoint.c (trace_buffer_size): New global.
15134	(DEFAULT_TRACE_BUFFER_SIZE): New define.
15135	(init_trace_buffer): Change to one-argument function. Allocate
15136	trace buffer memory.
15137	(handle_tracepoint_general_set): Call cmd_bigqtbuffer_size to
15138	handle QTBuffer:size packet.
15139	(cmd_bigqtbuffer_size): New function.
15140	(initialize_tracepoint): Call init_trace_buffer with
15141	DEFAULT_TRACE_BUFFER_SIZE.
15142	* server.c (handle_query): Add QTBuffer:size in the
15143	supported packets.
15144
151452013-03-07  Yao Qi  <yao@codesourcery.com>
15146
15147	* tracepoint.c (cur_action, cur_step_action): Make them unsigned.
15148	(cmd_qtfp): Initialize cur_action and cur_step_action 0 instead
15149	of -1.
15150	(cmd_qtsp): Adjust condition.  Do post increment.
15151	Set cur_action and cur_step_action back to 0.
15152
151532013-03-07  Jeremy Bennett  <jeremy.bennett@embecosm.com>
15154
15155	PR server/15236
15156	* linux-low.c (linux_write_memory): Return early success if LEN is
15157	zero.
15158
151592013-03-05  Corinna Vinschen  <vinschen@redhat.de>
15160
15161	* configure.srv: Add x86_64-*-cygwin* as target.
15162
151632013-02-28  Tom Tromey  <tromey@redhat.com>
15164
15165	* configure.ac: Invoke AC_SYS_LARGEFILE.
15166	* configure, config.in: Rebuild.
15167
151682013-02-28  Corinna Vinschen  <vinschen@redhat.com>
15169
15170	* win32-low.c: Throughout, fix format strings and casts of
15171	printf-like functions to avoid type related warnings on all
15172	platforms.
15173	(get_child_debug_event): Print dwDebugEventCode as hex since
15174	that's how it's usually documented.
15175
151762013-02-28  Yao Qi  <yao@codesourcery.com>
15177
15178	* tracepoint.c (cmd_qtbuffer): Call phex_nz instead of
15179	pulongest.
15180
151812013-02-27  Jiong Wang  <jiwang@tilera.com>
15182
15183	* Makefile.in (clean): Remove reg-tilegx.c, reg-tilegx32.c.
15184	(reg-tilegx32.c): New rule.
15185	* configure.srv (tilegx-*-linux*): Add reg-tilegx32.o to srv_regobj.
15186	* linux-tile-low.c (tile_arch_setup): New function.  Invoke
15187	different register info initializer according to elf class.
15188	(init_registers_tilgx32): New function.  The tilegx32 register info
15189	initializer.
15190	(tile_fill_gregset): Use "uint_reg_t" to represent register size.
15191	(tile_store_gregset): Likewise.
15192
151932013-02-27  Yao Qi  <yao@codesourcery.com>
15194
15195	* server.c (process_point_options): Print debug message when
15196	debug_threads is true.
15197
151982013-02-26  Yao Qi  <yao@codesourcery.com>
15199
15200	* tracepoint.c (cmd_qtbuffer): Don't set '\0' in OWN_BUF.
15201
152022013-02-19  Pedro Alves  <palves@redhat.com>
15203	    Kai Tietz <ktietz@redhat.com>
15204
15205	PR gdb/15161
15206
15207	* server.c (handle_query) <CRC check>: Use unpack_varlen_hex
15208	instead of strtoul to extract address from packet.
15209	(process_serial_event) <'z'>: Likewise.
15210
152112013-02-18  Yao Qi  <yao@codesourcery.com>
15212
15213	* linux-bfin-low.c (the_low_target): Use NULL instead of 0.
15214
152152013-02-14  Pedro Alves  <palves@redhat.com>
15216
15217	Plug memory leak.
15218
15219	* tracepoint.c (cmd_qtnotes): Free TRACING_USER_NAME,
15220	TRACING_NOTES and TRACING_STOP_NOTE before clobbering.
15221
152222013-02-14  Pedro Alves  <palves@redhat.com>
15223
15224	* tracepoint.c (cmd_qtdpsrc): Use savestring.
15225
152262013-02-14  Pedro Alves  <palves@redhat.com>
15227
15228	* tracepoint.c (save_string): Delete.
15229	(add_tracepoint_action): Use savestring instead of save_string.
15230
152312013-02-12  Pedro Alves  <palves@redhat.com>
15232
15233	* linux-xtensa-low.c: Ditto.
15234	* xtensa-xtregs.c: Ditto.
15235
152362013-02-12  Sanimir Agovic  <sanimir.agovic@intel.com>
15237
15238	* thread-db.c (thread_db_get_tls_address): NULL pointer check
15239	thread_db.
15240
152412013-02-07  Marcus Shawcroft  <marcus.shawcroft@arm.com>
15242
15243	* linux-aarch64-low.c (aarch64_arch_setup): Clamp
15244	aarch64_num_wp_regs and aarch64_num_bp_regs to
15245	AARCH64_HWP_MAX_NUM and AARCH64_HBP_MAX_NUM respectively.
15246
152472013-02-07  Marcus Shawcroft  <marcus.shawcroft@arm.com>
15248
15249	* linux-aarch64-low.c (ps_get_thread_area): Replace
15250	PTRACE_GET_THREAD_AREA with PTRACE_GETREGSET.
15251
152522013-02-04  Jim MacArthur  <jim.macarthur@arm.com>
15253	    Marcus Shawcroft  <marcus.shawcroft@arm.com>
15254	    Nigel Stephens  <nigel.stephens@arm.com>
15255	    Yufeng Zhang  <yufeng.zhang@arm.com>
15256
15257	* Makefile.in (clean): Remove aarch64.c and aarch64-without-fpu.c.
15258	(aarch64.c, aarch64-without-fpu.c): New targets.
15259	* configure.srv (aarch64*-*-linux*): New.
15260	* linux-aarch64-low.c: New file.
15261
152622013-02-04  Marcus Shawcroft  <marcus.shawcroft@arm.com>
15263
15264	* linux-low.c (handle_extended_wait, linux_create_inferior)
15265	(linux_attach_lwp_1, linux_kill_one_lwp, linux_attach_one_lwp)
15266	(dequeue_one_deferred_signal, linux_resume_one_thread)
15267	(fetch_register, linux_write_memory, linux_enable_event_reporting)
15268	(linux_tracefork_grandchild, linux_test_for_tracefork)
15269	(linux_read_offsets, linux_xfer_siginfo, linux_xfer_siginfo): Add
15270	PTRACE_ARG3_TYPE and PTRACE_ARG4_TYPE cast to ptrace arguments
15271	where the argument is 0.
15272
152732013-01-25  Yao Qi  <yao@codesourcery.com>
15274
15275	* event-loop.c: Include "queue.h".
15276	(gdb_event_p): New typedef.
15277	(struct gdb_event) <next_event>: Remove.
15278	(event_queue): Change to QUEUE(gdb_event_p).
15279	(async_queue_event): Remove.
15280	(gdb_event_xfree): New.
15281	(initialize_event_loop): New.
15282	(process_event): Use API from QUEUE.
15283	(wait_for_event): Likewise.
15284	* server.c (main): Call initialize_event_loop.
15285	* server.h (initialize_event_loop): Declare.
15286
152872013-01-18  Yao Qi  <yao@codesourcery.com>
15288
15289	* ax.h (struct eval_agent_expr_context): New.
15290	(gdb_eval_agent_expr): Update declaration.
15291	* ax.c (gdb_eval_agent_expr): Remove argument REGCACHE and
15292	TFRAME.  Add new argument CTX.
15293	* server.h (struct eval_agent_expr_context): Declare.
15294	(agent_mem_read, agent_tsv_read): Update declaration.
15295	(agent_mem_read_string): Likewise.
15296	* tracepoint.c (eval_tracepoint_agent_expr): Remove.
15297	(add_traceframe_block): Add new argument TPOINT.
15298	Increase TPOINT->traceframe_usage.
15299	(do_action_at_tracepoint): Call gdb_eval_agent_expr instead of
15300	eval_tracepoint_agent_expr.
15301	(condition_true_at_tracepoint): Likewise.
15302	(agent_mem_read): Remove argument TFRAME.  Add argument CTX.
15303	(agent_mem_read_string, agent_tsv_read): Likewise.
15304
153052013-01-16  Yao Qi  <yao@codesourcery.com>
15306
15307	* linux-low.c (linux_resume_one_lwp): Don't check
15308	'lwp->bp_reinsert != 0'.
15309
153102013-01-07  Joel Brobecker  <brobecker@adacore.com>
15311	    Pedro Alves  <palves@redhat.com>
15312
15313	* lynx-low.c (ptrace_request_to_str): Define a temporary
15314	macro and use it to simplify this function's implementation.
15315
153162013-01-07  Joel Brobecker  <brobecker@adacore.com>
15317
15318	* lynx-low.c (lynx_resume): Call perror_with_name if lynx_ptrace
15319	sets errno.
15320
153212013-01-07  Joel Brobecker  <brobecker@adacore.com>
15322
15323	* configure.srv (i[34567]86-*-lynxos*): Set srv_xmlfiles.
15324
153252013-01-07  Joel Brobecker  <brobecker@adacore.com>
15326
15327	* configure.srv (powerpc-*-lynxos*): Set srv_xmlfiles.
15328
153292013-01-07  Joel Brobecker  <brobecker@adacore.com>
15330
15331	* lynx-low.c (lynx_resume): Use the resume_info parameter
15332	to determine the ptid for the lynx_ptrace call, unless
15333	it is equal to minus_one_ptid, in which case we use the
15334	ptid of the current_inferior.
15335	(lynx_wait_1): After having received a thread create/exit
15336	event, resume the inferior's execution using the signaling
15337	thread's ptid, rather than the old ptid.
15338
153392013-01-07  Joel Brobecker  <brobecker@adacore.com>
15340
15341	* lynx-low.c (lynx_resume): Delete variable ret.
15342
153432013-01-01  Joel Brobecker  <brobecker@adacore.com>
15344
15345	* gdbreplay.c (gdbreplay_version): Update copyright year.
15346	* server.c (gdbserver_version): Likewise.
15347
153482012-12-17  Joel Brobecker  <brobecker@adacore.com>
15349
15350	* lynx-low.c (lynx_wait_1): Add debug trace before adding
15351	new thread.
15352
153532012-12-17  Joel Brobecker  <brobecker@adacore.com>
15354
15355	* lynx-low.c (ptrace_request_to_str): Add handling for
15356	PTRACE_GETTRACESIG.
15357
153582012-12-17  Joel Brobecker  <brobecker@adacore.com>
15359
15360	* lynx-low.c (lynx_attach): Delete variable new_process.
15361
153622012-12-17  Joel Brobecker  <brobecker@adacore.com>
15363
15364	* lynx-low.c (lynx_create_inferior): Delete variable
15365	new_process.
15366
153672012-12-17  Joel Brobecker  <brobecker@adacore.com>
15368
15369	* lynx-low.c (ptrace_request_to_str): Do not handle
15370	PTRACE_GETTHREADLIST if this macro does not exist.
15371
153722012-12-15  Yao Qi  <yao@codesourcery.com>
15373
15374	* Makefile.in (OBS): Add notif.o.
15375	* notif.c, notif.h: New.
15376	* server.c: Include "notif.h".
15377	(struct vstop_notif) <next>: Remove.
15378	<base>: New field.
15379	(queue_stop_reply): Update.
15380	(push_event, send_next_stop_reply): Remove.
15381	(discard_queued_stop_replies): Update.
15382	(notif_stop): New variable.
15383	(handle_v_stopped): Remove.
15384	(handle_v_requests): Don't call handle_v_stopped.  Call
15385	handle_ack_notif instead.
15386	(queue_stop_reply_callback): Call notif_event_enque instead
15387	of queue_stop_reply.
15388	(handle_status): Don't call send_next_stop_reply, call
15389	notif_write_event instead.
15390	(kill_inferior_callback): Likewise.
15391	(detach_or_kill_inferior_callback): Likewise.
15392	(main): Call initialize_notif.
15393	(process_serial_event): Call QUEUE_is_empty.
15394	(handle_target_event): Call notif_push instead of push event.
15395	* server.h (push_event): Remove declaration.
15396
153972012-12-10  Tom Tromey  <tromey@redhat.com>
15398
15399	* Makefile.in (DEPMODE, DEPDIR, depcomp, COMPILE.pre)
15400	(COMPILE.post, COMPILE, POSTCOMPILE, IPAGENT_COMPILE): New
15401	macros.
15402	(.c.o): Rewrite.
15403	(ax-ipa.o, tracepoint-ipa.o, utils-ipa.o, format-ipa.o)
15404	(common-utils-ipa.o, remote-utils-ipa.o, regcache-ipa.o)
15405	(i386-linux-ipa.o, linux-i386-ipa.o, linux-amd64-ipa.o)
15406	(amd64-linux-ipa.o, ax.o): Rewrite.
15407	(event-loop.o, hostio.o, hostio-errno.o, inferiors.o, mem-break.o)
15408	(proc-service.o, regcache.o, remote-utils.o, server.o, target.o)
15409	(thread-db.o, tracepoint.o, utils.o, gdbreplay.o, dll.o): Remove.
15410	(signals.o, linux-procfs.o, linux-ptrace.o, common-utils.o, vec.o)
15411	(gdb_vecs.o, xml-utils.o, linux-osdata.o, ptid.o, buffer.o)
15412	(format.o, agent.o, vasprintf.o, vsnprintf.o): Rewrite.
15413	(i386-low.o, i387-fp.o, linux-low.o, linux-arm-low.o)
15414	(linux-bfin-low.o, linux-cris-low.o, linux-crisv32-low.o)
15415	(linux-ia64-low.o, linux-m32r-low.o, linux-mips-low.o)
15416	(linux-ppc-low.o, linux-s390-low.o, linux-sh-low.o)
15417	(linux-tic6x-low.o, linux-x86-low.o, linux-xtensa-low.o)
15418	(linux-tile-low.o, lynx-low.o, lynx-ppc-low.o, nto-low.o)
15419	(nto-x86-low.o, linux-low.o, win32-low.o, win32-arm-low.o)
15420	(win32-i386-low.o, spu-low.o, reg-arm.o, arm-with-iwmmxt.o)
15421	(arm-with-vfpv2.o, arm-with-vfpv3.o, arm-with-neon.o, reg-bfin.o)
15422	(reg-cris.o, reg-crisv32.o, i386.o, i386-linux.o, i386-avx.o)
15423	(i386-avx-linux.o, i386-mmx.o, i386-mmx-linux.o, reg-ia64.o)
15424	(reg-m32r.o, reg-m68k.o, reg-cf.o, mips-linux.o, mips-dsp-linux.o)
15425	(mips64-linux.o, mips64-dsp-linux.o, powerpc-32.o, powerpc-32l.o)
15426	(powerpc-altivec32l.o, powerpc-cell32l.o, powerpc-vsx32l.o)
15427	(powerpc-isa205-32l.o, powerpc-isa205-altivec32l.o)
15428	(powerpc-isa205-vsx32l.o, powerpc-e500l.o, powerpc-64l.o)
15429	(powerpc-altivec64l.o, powerpc-cell64l.o, powerpc-vsx64l.o)
15430	(powerpc-isa205-64l.o, powerpc-isa205-altivec64l.o)
15431	(powerpc-isa205-vsx64l.o, s390-linux32.o, s390-linux32v1.o)
15432	(s390-linux32v2.o, s390-linux64.o, s390-linux64v1.o)
15433	(s390-linux64v2.o, s390x-linux64.o, s390x-linux64v1.o)
15434	(s390x-linux64v2.o, tic6x-c64xp-linux.o, tic6x-c64x-linux.o)
15435	(tic6x-c62x-linux.o, reg-sh.o, reg-sparc64.o, reg-spu.o, amd64.o)
15436	(amd64-linux.o, amd64-avx.o, amd64-avx-linux.o, x32.o)
15437	(x32-linux.o, x32-avx.o, x32-avx-linux.o, reg-xtensa.o)
15438	(reg-tilegx.o): Remove.
15439	(all_object_files): New macro.
15440	Include .deps files.
15441	* aclocal.m4, configure: Rebuild.
15442	* acinclude.m4: Include depstand.m4, lead-dot.m4.
15443	* configure.ac: Invoke ZW_CREATE_DEPDIR,
15444	ZW_PROG_COMPILER_DEPENDENCIES.  Compute GMAKE condition.
15445
154462012-12-05  Tom Tromey  <tromey@redhat.com>
15447
15448	PR gdb/14917:
15449	* server.h (current_insn_ptr, emit_error): Declare 'extern'.
15450
154512012-11-28  Markus Metzger  <markus.t.metzger@intel.com>
15452
15453	* configure.ac: Check for linux/perf_event.h.
15454	* config.in: Regenerated.
15455	* configure: Regenerated.
15456
154572012-11-26  Maxime Villard  <rustyBSD@gmx.fr>
15458
15459	* hostio.c (handle_readlink): Decrease buffer size
15460	parameter passed to readlink by one byte.
15461
154622012-11-26  Yao Qi  <yao@codesourcery.com>
15463
15464	* configure.ac (build_warnings): Append '-Wempty-body'.
15465	* configure: Regenerated.
15466	* linux-low.c (linux_create_inferior): Use braces for empty 'if'
15467	body.
15468
154692012-11-15  Pierre Muller  <muller@sourceware.org>
15470
15471	* configure.ac (AC_CHECK_HEADERS): Add wait.h header.
15472	* config.in: Regenerate.
15473	* configure: Regenerate.
15474	* linux-low.c: Use "gdb_stat.h" header instead of <sys/stat.h> header.
15475	Use "gdb_wait.h" header instead of <sys/wait.h> header.
15476	* lynx-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
15477	* remote-utils.c: Use "gdb_stat.h" header instead of <sys/stat.h>
15478	header.
15479	* server.c: Remove HAVE_WAIT_H conditional.  Use "gdb_wait.h" header
15480	instead of <sys/wait.h> header.
15481	* spu-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
15482
154832012-11-13 Markus Metzger  <markus.t.metzger@intel.com>
15484
15485	* Makefile.in: (INTERNAL_CFLAGS): Add -DGDBSERVER
15486	(various make rules): Remove -DGDBSERVER
15487
154882012-11-09  Yao Qi  <yao@codesourcery.com>
15489
15490	* spu-low.c (current_ptid): Move it to ..
15491	* gdbthread.h: ... here.  New.
15492	* remote-utils.c (read_ptid): Use macro 'current_ptid'.
15493	* server.c (myresume, process_serial_event): Likewise.
15494	* thread-db.c (thread_db_find_new_threads): Likewise.
15495	* tracepoint.c (run_inferior_command): Likewise.
15496
154972012-10-01  Andrew Burgess  <aburgess@broadcom.com>
15498
15499	* server.c (handle_search_memory_1): Include access length in
15500	warning message.
15501
155022012-09-05  Michael Brandt  <michael.brandt@axis.com>
15503
15504	* linux-crisv32-low.c: Fix compile errors.
15505
155062012-09-04  Yao Qi  <yao@codesourcery.com>
15507
15508	* tracepoint.c (cmd_qtsv): Adjust debug message.
15509	Don't check CUR_TPOINT.
15510
155112012-08-28  Yao Qi  <yao@codesourcery.com>
15512
15513	* ax.c, tracepoint.c: Replace ATTR_FORMAT with ATTRIBUTE_PRINTF.
15514	* server.h: Include 'libiberty.h' and 'ansidecl.h'.
15515	(ATTR_NORETURN, ATTR_FORMAT, ATTR_MALLOC): Remove.
15516	Remove declarations of xmalloc, xreallloc, xstrdup and
15517	freeargv.
15518	* Makefile.in (libiberty_h): New.
15519	(server_h): Append dependencies 'libiberty.h' and 'ansidecl.h'.
15520	(linux-bfin-low.o): Append dependency 'libiberty.h'.
15521
155222012-08-23  Yao Qi  <yao@codesourcery.com>
15523
15524	* server.h: Remove declaration of 'xsnprintf'.
15525
155262012-08-22  Keith Seitz  <keiths@redhat.com>
15527
15528	* server.h: Include build-gnulib-gbserver/config.h.
15529	* gdbreplay.c: Likewise.
15530
155312012-08-08  Doug Evans  <dje@google.com>
15532
15533	* Makefile.in (SFILES): Add gdb_vecs.c.
15534	(OBS): Add gdb_vecs.o.
15535	(gdb_vecs_h, host_defs_h): New variables.
15536	(thread-db.o): Add $(gdb_vecs_h) dependency.
15537	(gdb_vecs.o): New rule.
15538	* thread-db.c: #include "gdb_vecs.h".
15539	(thread_db_load_search): Use a vector to iterate over path elements.
15540	Handle text appearing after "$pdir".
15541
15542	* configure.ac: Add check for strstr.
15543	* config.in: Regenerate.
15544	* configure: Regenerate.
15545
155462012-08-02  Ulrich Weigand  <ulrich.weigand@linaro.org>
15547
15548	* hostio.c (handle_pread): If pread fails, fall back to attempting
15549	lseek/read.
15550	(handle_pwrite): Likewise for pwrite.
15551
155522012-08-01  Ulrich Weigand  <ulrich.weigand@linaro.org>
15553
15554	* linux-arm-low.c (arm_linux_hw_point_initialize): Distinguish
15555	between unsupported TYPE and unimplementable ADDR/LEN combination.
15556	(arm_insert_point): Act on new return value.
15557
155582012-07-31  Pedro Alves  <palves@redhat.com>
15559
15560	* server.c (process_point_options): Only skip tokens if we find
15561	one that is unrecognized.  Don't treat 'X' specially while
15562	skipping unrecognized tokens.
15563
155642012-07-30  Ulrich Weigand  <ulrich.weigand@linaro.org>
15565
15566	* linux-arm-low.c (arm_linux_hw_point_initialize): Do not attempt
15567	to 4-byte-align HW breakpoint addresses for Thumb.
15568
155692012-07-27  Yao Qi  <yao@codesourcery.com>
15570
15571	PR remote/14161.
15572
15573	* server.h: Declare gdb_agent_about_to_close.
15574	* target.c (kill_inferior): Include "agent.h".
15575	New.  Send command 'kill'.
15576	* target.h (kill_inferior): Removed macro.
15577	* tracepoint.c (gdb_agent_about_to_close): New.
15578	(gdb_agent_helper_thread): Handle command 'close'.
15579	Wait endlessly until the inferior stops.
15580	Install gdb_agent_remove_socket to atexit hook.
15581	(agent_socket_name): New static variable.
15582	(gdb_agent_socket_init): Replace local variable 'name' with
15583	'agent_socket_name'.
15584	(gdb_agent_remove_socket): New.
15585
155862012-07-27  Yao Qi  <yao@codesourcery.com>
15587
15588	* server.c (process_point_options): Stop at 'X' when parsing.
15589
155902012-07-19  Michael Eager  <eager@eagercon.com>
15591
15592	* i386-low.c (Z_packet_to_hw_type): Add Z_PACKET_HW_BP, translate
15593	to hw_execute.
15594	* linux-x86-low.c (x86_insert_point, x86_remove_point):
15595	Call i386_low_insert_watchpoint, i386_low_remove_watchpoint to add/del
15596	hardware breakpoint.
15597
155982012-07-07  Jan Kratochvil  <jan.kratochvil@redhat.com>
15599
15600	* gdbserver/linux-low.c (initialize_low): Call
15601	linux_ptrace_init_warnings.
15602
156032012-07-02  Doug Evans  <dje@google.com>
15604
15605	* mem-break.c (gdb_no_commands_at_breakpoint): Fix cast from
15606	pointer to int.
15607
156082012-07-02  Stan Shebs  <stan@codesourcery.com>
15609
15610	* Makefile.in (WARN_CFLAGS_NO_FORMAT): Define.
15611	(ax.o): Add it to build rule.
15612	(ax-ipa.o): Ditto.
15613	(OBS): Add format.o.
15614	(IPA_OBS): Add format.o.
15615	* server.c (handle_query): Claim support for breakpoint commands.
15616	(process_point_options): Add command case.
15617	(process_serial_event): Leave running if there are printfs in
15618	effect.
15619	* mem-break.h (any_persistent_commands): Declare.
15620	(add_breakpoint_commands): Declare.
15621	(gdb_no_commands_at_breakpoint): Declare.
15622	(run_breakpoint_commands): Declare.
15623	* mem-break.c (struct point_command_list): New struct.
15624	(struct breakpoint): New field command_list.
15625	(any_persistent_commands): New function.
15626	(add_commands_to_breakpoint): New function.
15627	(add_breakpoint_commands): New function.
15628	(gdb_no_commands_at_breakpoint): New function.
15629	(run_breakpoint_commands): New function.
15630	* linux-low.c (linux_wait_1): Test for and run breakpoint commands
15631	locally.
15632	* ax.c: Include format.h.
15633	(ax_printf): New function.
15634	(gdb_eval_agent_expr): Add printf opcode.
15635
156362012-06-13  Yao Qi  <yao@codesourcery.com>
15637
15638	* server.c (start_inferior): Remove duplicated writes to fields
15639	'last_resume_kind' and 'last_status' of 'current_inferior'.
15640
156412012-06-12  Yao Qi  <yao@codesourcery.com>
15642	    Pedro Alves  <palves@redhat.com>
15643
15644	* linux-low.c (linux_set_resume_request): Simplify predicate.  Add
15645	comment.
15646	* server.c (handle_v_cont): Extend comment.
15647
156482012-06-11  Yao Qi  <yao@codesourcery.com>
15649
15650	* linux-low.c (linux_attach): Add 'static'.
15651
156522012-06-06  Yao Qi  <yao@codesourcery.com>
15653
15654	* ax.c (gdb_eval_agent_expr): Print `top' in hex.
15655
156562012-06-01  Jan Kratochvil  <jan.kratochvil@redhat.com>
15657
15658	Fix gcc -flto compilation warning.
15659	* server.c (main): Make variable multi_mode and attach volatile.
15660
156612012-05-30  Thiago Jung Bauermann  <thiago.bauermann@linaro.org>
15662
15663	* linux-low.c (get_r_debug): Disable code using DT_MIPS_RLD_MAP
15664	if the platform doesn't know about it.
15665
156662012-05-30  Jeff Kenton  <jkenton@tilera.com>
15667
15668	* Makefile.in (SFILES): Add linux-tile-low.c.
15669	(linux-tile-low.o, reg-tilegx.o, reg-tilegx.c): New rules.
15670	* configure.srv: Handle tilegx-*-linux*.
15671	* linux-tile-low.c: New file.
15672
156732012-05-28  Jan Kratochvil  <jan.kratochvil@redhat.com>
15674
15675	* linux-low.c (linux_qxfer_libraries_svr4): Return -1 if R_DEBUG is -1.
15676
156772012-05-24  Pedro Alves  <palves@redhat.com>
15678
15679	PR gdb/7205
15680
15681	Replace TARGET_SIGNAL_ with GDB_SIGNAL_ throughout.
15682
156832012-05-24  Pedro Alves  <palves@redhat.com>
15684
15685	PR gdb/7205
15686
15687	Replace target_signal with gdb_signal throughout.
15688
156892012-05-22  Maciej W. Rozycki  <macro@codesourcery.com>
15690
15691	* linux-low.c (linux_store_registers): Avoid the copying sequence
15692	when no data has been retrieved by ptrace.
15693
156942012-05-22  Will Deacon  <will.deacon@arm.com>
15695
15696	* linux-low (__UCLIBC__ && !(__UCLIBC_HAS_MMU__ || __ARCH_HAS_MMU__)):
15697	Include asm/ptrace.h.
15698	(PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define only if not
15699	already defined.
15700
157012012-05-21  Maciej W. Rozycki  <macro@codesourcery.com>
15702
15703	* linux-low.c (linux_store_registers): Don't re-retrieve data
15704	with ptrace that has already been obtained from /proc.  Always
15705	copy any data retrieved with ptrace to the buffer supplied.
15706
157072012-05-11  Yao Qi  <yao@codesourcery.com>
15708	    Pedro Alves  <palves@redhat.com>
15709
15710	* linux-low.c (enum stopping_threads_kind): New.
15711	(stopping_threads): Change type to `enum stopping_threads_kind'.
15712	(handle_extended_wait): If stopping and suspending threads, leave
15713	the new_lwp suspended too.
15714	(linux_wait_for_event): Adjust.
15715	(stop_all_lwps): Set `stopping_threads' to
15716	STOPPING_AND_SUSPENDING_THREADS or STOPPING_THREADS depending on
15717	whether we're suspending threads or just stopping them.  Assert no
15718	recursion happens.
15719
157202012-04-29  Yao Qi  <yao@codesourcery.com>
15721
15722	* server.h: Move some code to ...
15723	* gdbthread.h: ... here.  New.
15724	* Makefile.in (inferiors.o, regcache.o): Depends on gdbthread.h
15725	(remote-utils.o, server.o, target.o tracepoint.o): Likewise.
15726	(nto-low.o, win32-low.o): Likewise.
15727	* inferiors.c, linux-low.h, nto-low.c: Include gdbthread.h.
15728	* regcache.c, remote-utils.c, server.c: Likewise.
15729	* target.c, tracepoint.c, win32-low.c: Likewise.
15730
157312012-04-24  Thiago Jung Bauermann  <thiago.bauermann@linaro.org>
15732
15733	* linux-low.h (PTRACE_ARG3_TYPE): Move macro from linux-low.c.
15734	(PTRACE_ARG4_TYPE): Likewise.
15735	(PTRACE_XFER_TYPE): Likewise.
15736	* linux-arm-low.c (arm_prepare_to_resume): Cast third argument of
15737	ptrace to PTRACE_ARG3_TYPE.
15738	* linux-low.c (PTRACE_ARG3_TYPE): Move macro to linux-low.h.
15739	(PTRACE_ARG4_TYPE): Likewise.
15740	(PTRACE_XFER_TYPE): Likewise.
15741	(linux_detach_one_lwp): Cast fourth argument of
15742	ptrace to long then PTRACE_ARG4_TYPE.
15743	(regsets_fetch_inferior_registers): Cast third argument of
15744	ptrace to long then PTRACE_ARG3_TYPE.
15745	(regsets_store_inferior_registers): Likewise.
15746
157472012-04-20  Pedro Alves  <palves@redhat.com>
15748
15749	* configure: Regenerate.
15750
157512012-04-19  Pedro Alves  <palves@redhat.com>
15752
15753	* Makefile.in (GNULIB_BUILDDIR): New.
15754	(LIBGNU, INCGNU, GNULIB_H): Adjust.
15755	(SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): New.
15756	(all, install-only, uninstall, clean-info, all-lib, clean): No
15757	longer pass GNULIB_FLAGS_TO_PASS.  Use subdir_do.
15758	(maintainer-clean realclean distclean): Use subdir_do.
15759	(subdir_do): New.
15760	(gnulib/import/Makefile): Adjust.  Replace gnulib/import with
15761	$(GNULIB_BUILDDIR).  Don't pass argument to config.status.
15762	* acinclude.m4: Include acx_configure_dir.m4.
15763	* configure.ac: Remove gl_EARLY, gl_INIT, and AM_INIT_AUTOMAKE
15764	calls.	Call AC_PROG_RANLIB.  Configure gnulib using
15765	ACX_CONFIGURE_DIR.
15766	(GNULIB): New.
15767	(GNULIB_STDINT_H): Adjust.
15768	(AC_OUTPUT): Don't output gnulib/Makefile anymore.
15769	* gdbreplay.c: Include build-gnulib/config.h.
15770	* server.h: Likewise.
15771	* aclocal.m4: Regenerate.
15772	* config.in: Regenerate.
15773	* configure: Regenerate.
15774
157752012-04-19  Pedro Alves  <palves@redhat.com>
15776
15777	* Makefile.in (LIBGNU, INCGNU): Adjust.
15778	(GNULIB_FLAGS_TO_PASS, GNULIB_H): Adjust.
15779	(all, install-only, uninstall, clean-info, all-lib, clean)
15780	(maintainer-clean, Makefile, gnulib/Makefile): Adjust.
15781	* configure.ac: Adjust AC_OUTPUT output.
15782	* aclocal.m4: Regenerate.
15783	* configure: Regenerate.
15784
157852012-04-19  Pedro Alves  <palves@redhat.com>
15786
15787	* Makefile.in (generated_files): New.
15788	(server_h): Remove the explicit dependency on config.h, and depend
15789	on $generated_files.
15790
157912012-04-19  Pedro Alves  <palves@redhat.com>
15792
15793	* Makefile.in (INCGNU): Add -Ignulib.
15794
157952012-04-19  Pedro Alves  <palves@redhat.com>
15796
15797	* Makefile.in (GNULIB_INCLUDE_DIR): Rename to ...
15798	(INCGNU): ... this, and spell out -I here.
15799	(GNULIB_LIB): Rename to ...
15800	(LIBGNU): ... this.
15801	(INCLUDE_CFLAGS, gdbserver$(EXEEXT), $(GNULIB_LIB) rule): Adjust.
15802
158032012-04-19  Pedro Alves  <palves@redhat.com>
15804
15805	* config.in: Regenerate.
15806
158072012-04-19  Pedro Alves  <palves@redhat.com>
15808
15809	* configure.ac: Remove AC_CHECK_DECLS check for memmem.
15810	* server.h (memmem): Remove declaration.
15811	* config.in: Regenerate.
15812	* configure: Regenerate.
15813
158142012-04-19  Yao Qi  <yao@codesourcery.com>
15815
15816	* Makefile.in (SFILES): Add common/vec.c.
15817	(OBS): Add vec.o.
15818	(vec.o): New rule.
15819
158202012-04-19  Yao Qi  <yao@codesourcery.com>
15821
15822	* remote-utils.c (prepare_resume_reply): Replace with macro
15823	target_core_of_thread.
15824	* server.c (handle_qxfer_threads_proper): Likewise.
15825	* target.h (traget_core_of_thread): New macro.
15826
158272012-04-18  Pedro Alves  <palves@redhat.com>
15828
15829	* aclocal.m4: Regenerate.
15830	* configure: Regenerate.
15831
158322012-04-16  Yao Qi  <yao@codesourcery.com>
15833
15834	* tracepoint.c (cmd_qtstart): Download tracepoints even when they are
15835	duplicated on address.
15836
158372012-04-16  Yao Qi  <yao@codesourcery.com>
15838
15839	* tracepoint.c (COPY_FIELD_TO_BUF): New macro.
15840	(struct tracepoint_action_ops) <send>: New field.
15841	(m_tracepoint_action_send, r_tracepoint_action_send): New.
15842	(agent_expr_send, x_tracepoint_action_send): New.
15843	(l_tracepoint_action_send): New.
15844	(cmd_qtdp): Download and install tracepoint
15845	according to `use_agent'.
15846	(run_inferior_command): Add one more parameter `len'.
15847	Update callers.
15848	(tracepoint_send_agent): New.
15849	(cmd_qtdp, cmd_qtstart): Call tracepoint_send_agent.
15850
158512012-04-16  Yao Qi  <yao@codesourcery.com>
15852
15853	* tracepoint.c (download_tracepoints): Moved to ...
15854	(cmd_qtstart): ... here.
15855
158562012-04-14  Yao Qi  <yao@codesourcery.com>
15857
15858	* tracepoint.c: Include inttypes.h.
15859	(struct collect_memory_action): Use sized types.
15860	(struct tracepoint): Likewise.
15861	(cmd_qtdp, stop_tracing): Update print specifiers.
15862	(cmd_qtp, response_tracepoint): Likewise.
15863	(collect_data_at_tracepoint): Likewise.
15864	(collect_data_at_step): Likewise.
15865
158662012-04-14  Yao Qi  <yao@codesourcery.com>
15867
15868	Import gnulib module inttypes.
15869	* aclocal.m4, config.in, configure: Regenerated.
15870
158712012-04-14  Yao Qi  <yao@codesourcery.com>
15872
15873	* Makefile.in (maintainer-clean, realclean, distclean): Remove
15874	Makefile and config.status at last.
15875
158762012-04-13  Yao Qi  <yao@codesourcery.com>
15877
15878	* tracepoint.c: Include stdint.h unconditionally.
15879
158802012-04-13  Thiago Jung Bauermann  <thiago.bauermann@linaro.org>
15881
15882	* acinclude.m4 (GDBSERVER_HAVE_THREAD_DB_TYPE): New macro based
15883	on BFD_HAVE_SYS_PROCFS_TYPE.
15884	* configure.ac: Look for lwpid_t and psaddr_t in libthread_db.h.
15885	* configure: Regenerate.
15886	* config.in: Likewise.
15887
158882012-04-13  H.J. Lu  <hongjiu.lu@intel.com>
15889
15890	* Makefile.in (clean): Also remove x32.c x32-linux.c
15891	x32-avx.c x32-avx-linux.c.
15892	(x32.o): New target.
15893	(x32.c): Likewise.
15894	(x32-linux.o): Likewise.
15895	(x32-linux.c): Likewise.
15896	(x32-avx.o): Likewise.
15897	(x32-avx.c): Likewise.
15898	(x32-avx-linux.o): Likewise.
15899	(x32-avx-linux.c): Likewise.
15900
15901	* configure.srv (srv_amd64_regobj): Add x32.o x32-avx.o.
15902	(srv_amd64_linux_regobj): Add x32-linux.o x32-avx-linux.o.
15903	(srv_i386_64bit_xmlfiles): Add i386/x32-core.xml.
15904	(srv_amd64_xmlfiles): Add i386/x32.xml i386/x32-avx.xml.
15905	(srv_amd64_linux_xmlfiles): Add i386/x32-linux.xml
15906	i386/x32-avx-linux.xml.
15907
15908	* linux-x86-low.c (init_registers_x32_linux): New prototype.
15909	(init_registers_x32_avx_linux): Likwise.
15910	(x86_linux_update_xmltarget): Call init_registers_x32_linux
15911	or init_registers_x32_avx_linux if linux_is_elf64 is false.
15912
159132012-04-13  Pedro Alves  <palves@redhat.com>
15914
15915	* Makefile.in (GNULIB_FLAGS_TO_PASS): New.
15916	(FLAGS_TO_PASS): Don't change or set $top_srcdir, $srcdir and VPATH.
15917	(all, uninstall, clean-info, all-lib, clean, maintainer-clean)
15918	(realclean, distclean): Explicitly pass $GNULIB_FLAGS_TO_PASS to
15919	the sub-make.
15920
159212012-04-12  H.J. Lu  <hongjiu.lu@intel.com>
15922
15923	* linux-x86-low.c (compat_x32_clock_t): New.
15924	(compat_x32_siginfo_t): Likewise.
15925	(compat_x32_siginfo_from_siginfo): Likewise.
15926	(siginfo_from_compat_x32_siginfo): Likewise.
15927	(linux_is_elf64): Likewise.
15928	(x86_siginfo_fixup): Call compat_x32_siginfo_from_siginfo
15929	and siginfo_from_compat_x32_siginfo for x32.
15930	(x86_arch_setup): Set linux_is_elf64.
15931
159322012-04-12  H.J. Lu  <hongjiu.lu@intel.com>
15933
15934	PR gdb/13969
15935	* linux-low.c (linux_pid_exe_is_elf_64_file): Also return the
15936	e_machine field.
15937	(linux_qxfer_libraries_svr4): Update call to elf_64_file_p.
15938	* linux-low.h (linux_pid_exe_is_elf_64_file): Updated.
15939	* linux-x86-low.c (x86_arch_setup): Check if GDBserver is
15940	compatible with process.
15941
159422012-04-12  Yao Qi  <yao@codesourcery.com>
15943
15944	* Makefile.in: Define abs_top_srcdir and abs_srcdir.
15945	(INCLUDE_CFLAGS): Append GNULIB_INCLUDE_DIR.
15946	(install-only, install-info, clean): Handle sub dir gnulib.
15947	(all-lib, am--refresh): New targets.
15948	(memmem.o): Remove target.
15949	* configure.ac: Remove AC_CONFIG_LIBOBJ_DIR.
15950	Invoke gl_EARLY.  Invoke AC_CHECK_PROGS for make.
15951	(AC_REPLACE_FUNCS): Remove memmem.
15952	Invoke gl_INIT and AM_INIT_AUTOMAKE.
15953	(AC_OUTPUT): Generate Makefile in gnulib/.
15954	* aclocal.m4, config.in, configure: Regenerated.
15955
159562012-04-10  Maciej W. Rozycki  <macro@codesourcery.com>
15957
15958	* linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP.
15959
159602012-04-05  Pedro Alves  <palves@redhat.com>
15961
15962	-Werror=strict-aliasing
15963
15964	* spu-low.c (parse_spufs_run): Avoid dereferencing type-punned
15965	pointer.
15966
159672012-04-04  Pedro Alves  <palves@redhat.com>
15968
15969	* linux-sparc-low.c (sparc_fill_gregset_to_stack)
15970	(sparc_store_gregset_from_stack, sparc_store_gregset)
15971	(sparc_breakpoint_at): Fix formatting.
15972
159732012-03-30  Thiago Jung Bauermann  <thiago.bauermann@linaro.org>
15974
15975	* configure.ac: Check whether Elf32_auxv_t and Elf64_auxv_t
15976	are available.
15977	* linux-low.c [HAVE_ELF32_AUXV_T] (Elf32_auxv_t): Add typedef.
15978	[HAVE_ELF64_AUXV_T] (Elf64_auxv_t): Likewise.
15979	* config.in: Regenerate.
15980	* configure: Likewise.
15981
159822012-03-29  Pedro Alves  <palves@redhat.com>
15983
15984	* linux-low.c (regsets_store_inferior_registers) [__sparc__]:
15985	Correct ptrace arguments.
15986
159872012-03-28  Pedro Alves  <palves@redhat.com>
15988
15989	* linux-ia64-low.c (ia64_regmap): Map IA64_EC_REGNUM to PT_AR_EC.
15990	(IA64_GR0_REGNUM, IA64_FR0_REGNUM)
15991	(IA64_FR1_REGNUM): New defines.
15992	(ia64_fetch_register): New.
15993	(the_low_target): Install it.
15994	* linux-low.h (struct linux_target_ops) <fetch_register>: New
15995	field.
15996	* linux-low.c (linux_fetch_registers): Try the
15997	the_low_target.fetch_register hook first.
15998
15999	* linux-arm-low.c (the_low_target): Adjust.
16000	* linux-bfin-low.c (the_low_target): Adjust.
16001	* linux-cris-low.c (the_low_target): Adjust.
16002	* linux-crisv32-low.c (the_low_target): Adjust.
16003	* linux-m32r-low.c (the_low_target): Adjust.
16004	* linux-m68k-low.c (the_low_target): Adjust.
16005	* linux-mips-low.c (the_low_target): Adjust.
16006	* linux-ppc-low.c (the_low_target): Adjust.
16007	* linux-s390-low.c (the_low_target): Adjust.
16008	* linux-sh-low.c (the_low_target): Adjust.
16009	* linux-sparc-low.c (the_low_target): Adjust.
16010	* linux-tic6x-low.c (the_low_target): Adjust.
16011	* linux-x86-low.c (the_low_target): Adjust.
16012	* linux-xtensa-low.c (the_low_target): Adjust.
16013
160142012-03-26  Pedro Alves  <palves@redhat.com>
16015
16016	* server.c (handle_qxfer_libraries): Don't bail early if
16017	the_target->qxfer_libraries_svr4 is not NULL.
16018
160192012-03-26  Pedro Alves  <palves@redhat.com>
16020
16021	* linux-low.c (linux_qxfer_libraries_svr4): Fix pasto in comment.
16022
160232012-03-23  Pedro Alves  <palves@redhat.com>
16024
16025	* linux-low.c (linux_qxfer_libraries_svr4): Terminate the
16026	"library-list-svr4" element's start tag when the the DSO list is
16027	empty.
16028
160292012-03-23  Pedro Alves  <palves@redhat.com>
16030
16031	* linux-low.c (read_one_ptr): Read the inferior's pointer through
16032	a variable whose type size is the same as the inferior's pointer
16033	size.
16034
160352012-03-21  Thomas Schwinge  <thomas@codesourcery.com>
16036
16037	* linux-arm-low.c (arm_stopped_by_watchpoint): Use siginfo_t instead of
16038	struct siginfo.
16039	* linux-low.c (siginfo_fixup, linux_xfer_siginfo): Likewise.
16040	* linux-x86-low.c (x86_siginfo_fixup): Likewise.
16041	* linux-low.h: Include <signal.h>.
16042	(struct siginfo): Remove forward declaration.
16043	(struct linux_target_ops) <siginfo_fixup>: Use siginfo_t instead of
16044	struct siginfo.
16045
160462012-03-21  Mike Frysinger  <vapier@gentoo.org>
16047
16048	* .gitignore: Ignore more files.
16049
160502012-03-19  Pedro Alves  <palves@redhat.com>
16051	    Jan Kratochvil  <jan.kratochvil@redhat.com>
16052
16053	* server.c (cont_thread, general_thread): Add describing comments.
16054	(start_inferior): Clear `cont_thread'.
16055	(handle_v_cont): Don't set `cont_thread' if resuming all threads
16056	of a process.
16057
160582012-03-15  Yao Qi  <yao@codesourcery.com>
16059
16060	* tracepoint.c (install_tracepoint): Move duplicated tracepoint
16061	handling to ...
16062	(cmd_qtdp): ... here.
16063
160642012-03-15  Yao Qi  <yao@codesourcery.com>
16065
16066	* tracepoint.c (struct tracepoint_action_ops): New.
16067	(struct tracepoint_action) [!IN_PROCESS_AGENT] <ops>: New field.
16068	(m_tracepoint_action_download): New.
16069	(r_tracepoint_action_download): New.
16070	(x_tracepoint_action_download): New.
16071	(l_tracepoint_action_download): New.
16072	(add_tracepoint_action): Install `action->ops' according type.
16073	(download_tracepoint_1): Move code `download' function pointer
16074	of various tracepoint_action_ops.
16075
160762012-03-13  Jan Kratochvil  <jan.kratochvil@redhat.com>
16077
16078	* linux-low.c (linux_attach_lwp_1): New variable buffer.  Call
16079	linux_ptrace_attach_warnings.
16080
160812012-03-13  Jan Kratochvil  <jan.kratochvil@redhat.com>
16082
16083	* Makefile.in (linux-ptrace.o): New.
16084	* configure.srv (arm*-*-linux*, bfin-*-*linux*, crisv32-*-linux*)
16085	(cris-*-linux*, i[34567]86-*-linux*, ia64-*-linux*, m32r*-*-linux*)
16086	(m68*-*-linux*, m68*-*-uclinux*, mips*-*-linux*, powerpc*-*-linux*)
16087	(s390*-*-linux*, sh*-*-linux*, sparc*-*-linux*, tic6x-*-uclinux)
16088	(x86_64-*-linux*, xtensa*-*-linux*): Add linux-ptrace.o to SRV_TGTOBJ
16089	of these targets.
16090	* linux-low.c (linux_attach_lwp_1): Remove redundent else clause.
16091
160922012-03-08  Yao Qi  <yao@codesourcery.com>
16093	    Pedro Alves  <palves@redhat.com>
16094
16095	Fix PR server/13392.
16096	* linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Check
16097	offset of JMP insn.
16098	* tracepoint.c (remove_tracepoint): New.
16099	(cmd_qtdp): Call remove_tracepoint when failed to install.
16100
161012012-03-07  Pedro Alves  <palves@redhat.com>
16102
16103	* linux-low.c (get_detach_signal): New.
16104	(linux_detach_one_lwp): Get rid of a pending SIGSTOP with SIGCONT.
16105	Pass on pending signals to PTRACE_DETACH.  Check the result of the
16106	ptrace call.
16107	* server.c (program_signals, program_signals_p): New.
16108	(handle_general_set): Handle QProgramSignals.
16109	* server.h (program_signals, program_signals_p): Declare.
16110
161112012-03-05  Pedro Alves  <palves@redhat.com>
16112	    Jan Kratochvil  <jan.kratochvil@redhat.com>
16113
16114	* linux-low.c (get_dynamic): Don't warn when PT_PHDR isn't found.
16115	New comment why.
16116
161172012-03-03  Yao Qi  <yao@codesourcery.com>
16118
16119	* tracepoint.c (tracepoint_look_up_symbols): Update call to
16120	agent_look_up_symbols.
16121
161222012-03-03  Yao Qi  <yao@codesourcery.com>
16123
16124	* Makefile.in (linux-low.o): Keep dependence on agent.h.
16125	(linux-x86-low.o): Likewise.
16126	* server.h: Remove in_process_agent_loaded.
16127	* tracepoint.c (in_process_agent_loaded): Removed.  Moved it
16128	common/agent.c.
16129	Update callers.
16130
161312012-03-03  Yao Qi  <yao@codesourcery.com>
16132
16133	* tracepoint.c (gdb_agent_capability): New global.
16134	(in_process_agent_loaded_ust): Renamed to
16135	`in_process_agent_supports_ust'.
16136	Update callers.
16137	(in_process_agent_supports_ust): Call agent_capability_check.
16138	(clear_installed_tracepoints): Assert that agent supports
16139	agent.
16140
161412012-03-03  Yao Qi  <yao@codesourcery.com>
16142
16143	* linux-low.c (linux_supports_agent): New.
16144	(linux_target_ops): Initialize field `supports_agent' with
16145	linux_supports_agent.
16146	* target.h (struct target_ops) <supports_agent>: New.
16147	(target_supports_agent): New macro.
16148	* server.c (handle_general_set): Handle packet 'QAgent'.
16149	(handle_query): Send `QAgent+'.
16150	* Makefile.in (server.o): Depends on agent.h.
16151
161522012-03-03  Yao Qi  <yao@codesourcery.com>
16153
16154	* Makefile.in (OBS): Add agent.o.
16155	Add new rule for agent.o.
16156	Track dependence of tracepoint.c on agent.h.
16157	* tracepoint.c (run_inferior_command_1):
16158	(run_inferior_command): Call agent_run_command.
16159	(gdb_ust_connect_sync_socket): Deleted.  Move it to
16160	common/agent.c.
16161	(resume_thread, stop_thread): Likewise.
16162	(gdb_ust_socket_init): Renamed to ...
16163	(gdb_agent_socket_init): ... New.
16164	(gdb_ust_thread): Renamed to ...
16165	(gdb_agent_helper_thread): ... New.
16166	(gdb_ust_init): Move some code to ...
16167	(gdb_agent_init): ... here.  New.
16168	[HAVE_UST]: Call gdb_ust_init.
16169	(initialize_tracepoint_ftlib):  Call gdb_agent_init.
16170	* configure.ac: Add `sys/un.h' to AC_CHECK_HEADERS.
16171	* config.in, configure: Regenerated.
16172
161732012-03-02  Pedro Alves  <palves@redhat.com>
16174
16175	* inferiors.c (add_pid_to_list, pull_pid_from_list): Delete.
16176	* linux-low.c (struct simple_pid_list): New.
16177	(stopped_pids): New a struct simple_pid_list pointer.
16178	(add_to_pid_list, pull_pid_from_list): New.
16179	(handle_extended_wait): Don't assume the first signal new children
16180	report is SIGSTOP.  Adjust call to pull_pid_from_list.
16181	(linux_wait_for_lwp): Adjust.
16182
161832012-03-02  Yao Qi  <yao@codesourcery.com>
16184
16185	* tracepoint.c (do_action_at_tracepoint): Write `stop_pc' in
16186	debug log.
16187
161882012-03-02  Yao Qi  <yao@codesourcery.com>
16189
16190	* tracepoint.c (collect_ust_data_at_tracepoint): Remove parameters
16191	`stop_pc' and `tpoint'.  Update caller.
16192
161932012-03-01  Maciej W. Rozycki  <macro@codesourcery.com>
16194
16195	* linux-low.h (linux_target_ops): Add regset_bitmap member.
16196	* linux-low.c (use_linux_regsets): New macro.
16197	[!HAVE_LINUX_REGSETS] (regsets_fetch_inferior_registers): Likewise.
16198	[!HAVE_LINUX_REGSETS] (regsets_store_inferior_registers): Likewise.
16199	(linux_register_in_regsets): New function.
16200	(usr_fetch_inferior_registers): Skip registers covered by
16201	regsets.
16202	(usr_store_inferior_registers): Likewise.
16203	(usr_fetch_inferior_registers): New macro.
16204	(usr_store_inferior_registers): Likewise.
16205	(linux_fetch_registers): Handle mixed regset/non-regset targets.
16206	(linux_store_registers): Likewise.
16207	* linux-mips-low.c (init_registers_mips_dsp_linux): New
16208	prototype.
16209	(init_registers_mips64_dsp_linux): Likewise.
16210	(init_registers_mips_linux): New macro.
16211	(init_registers_mips_dsp_linux): Likewise.
16212	(mips_dsp_num_regs): Likewise.
16213	(DSP_BASE, DSP_CONTROL): New fallback macros.
16214	(mips_base_regs): New macro.
16215	(mips_regmap): Use it.  Fix the size.
16216	(mips_dsp_regmap): New variable.
16217	(mips_dsp_regset_bitmap): Likewise.
16218	(mips_arch_setup): New function.
16219	(mips_cannot_fetch_register): Use the_low_target.regmap rather
16220	than mips_regmap.
16221	(mips_cannot_store_register): Likewise.
16222	(the_low_target): Update .arch_setup, .num_regs and .regmap
16223	initializers.  Add .regset_bitmap initializer.
16224	* linux-arm-low.c (the_low_target): Add .regset_bitmap
16225	initializer.
16226	* linux-bfin-low.c (the_low_target): Likewise.
16227	* linux-cris-low.c (the_low_target): Likewise.
16228	* linux-crisv32-low.c (the_low_target): Likewise.
16229	* linux-ia64-low.c (the_low_target): Likewise.
16230	* linux-m32r-low.c (the_low_target): Likewise.
16231	* linux-m68k-low.c (the_low_target): Likewise.
16232	* linux-ppc-low.c (the_low_target): Likewise.
16233	* linux-s390-low.c (the_low_target): Likewise.
16234	* linux-sh-low.c (the_low_target): Likewise.
16235	* linux-sparc-low.c (the_low_target): Likewise.
16236	* linux-tic6x-low.c (the_low_target): Likewise.
16237	* linux-x86-low.c (the_low_target): Likewise.
16238	* linux-xtensa-low.c (the_low_target): Likewise.
16239	* configure.srv <mips*-*-linux*>: Add mips-dsp-linux.o and
16240	mips64-dsp-linux.o to srv_regobj.  Add mips-dsp-linux.xml,
16241	mips64-dsp-linux.xml, mips-dsp.xml and mips64-dsp.xml to
16242	srv_xmlfiles.
16243	* Makefile.in (mips-dsp-linux.o, mips-dsp-linux.c): New targets.
16244	(mips64-dsp-linux.o, mips64-dsp-linux.c): Likewise.
16245
162462012-02-29  Yao Qi  <yao@codesourcery.com>
16247	    Pedro Alves  <palves@redhat.com>
16248
16249	* linux-low.c: (linux_wait_1): Call unsuspend_all_lwps when
16250	`step_over_finished' is true.
16251
162522012-02-27  Pedro Alves  <palves@redhat.com>
16253
16254	* linux-low.c (pid_is_stopped): Delete, moved to common/.
16255	(linux_attach_lwp_1): Adjust to use linux_proc_pid_is_stopped.
16256
162572012-02-27  Pedro Alves  <palves@redhat.com>
16258
16259	PR server/9684
16260	* linux-low.c (pid_is_stopped): New.
16261	(linux_attach_lwp_1): Handle attaching to 'T (stopped)' processes.
16262
162632012-02-25  Luis Machado  <lgustavo@codesourcery.com>
16264
16265	* mem-break.c (clear_gdb_breakpoint_conditions): Fix de-allocation
16266	of conditions.
16267
162682012-02-24  Maciej W. Rozycki  <macro@codesourcery.com>
16269
16270	* linux-mips-low.c (mips_regmap): Correct the index of $f9.
16271
162722012-02-24  Luis Machado  <lgustavo@codesourcery>
16273
16274	* server.c (handle_query): Advertise support for target-side
16275	breakpoint condition evaluation.
16276	(process_point_options): New function.
16277	(process_serial_event): When inserting a breakpoint, check for
16278	a target-side condition that should be evaluated.
16279
16280	* mem-break.c: Include regcache.h and ax.h.
16281	(point_cond_list_t): New data structure.
16282	(breakpoint) <cond_list>: New field.
16283	(find_gdb_breakpoint_at): Make non-static.
16284	(delete_gdb_breakpoint_at): Clear any target-side
16285	conditions.
16286	(clear_gdb_breakpoint_conditions): New function.
16287	(add_condition_to_breakpoint): Likewise.
16288	(add_breakpoint_condition): Likewise.
16289	(gdb_condition_true_at_breakpoint): Likewise.
16290	(gdb_breakpoint_here): Return result directly instead
16291	of going through a local variable.
16292
16293	* mem-break.h (find_gdb_breakpoint_at): New prototype.
16294	(clear_gdb_breakpoint_conditions): Likewise.
16295	(add_breakpoint_condition): Likewise.
16296	(gdb_condition_true_at_breakpoint): Likewise.
16297
16298	* linux-low.c (linux_wait_1): Evaluate target-side breakpoint condition.
16299	(need_step_over_p): Take target-side breakpoint condition into
16300	consideration.
16301
163022012-02-24  Luis Machado  <lgustavo@codesourcery>
16303
16304	* server.h: Include tracepoint.h.
16305	(agent_mem_read, agent_get_trace_state_variable_value,
16306	agent_set_trace_state_variable_value,
16307	agent_tsv_read, agent_mem_read_string, get_get_tsv_func_addr,
16308	get_set_tsv_func_addr): New prototypes.
16309
16310	* ax.h: New include file.
16311	* ax.c: New source file.
16312
16313	* tracepoint.c: Include ax.h.
16314	(gdb_agent_op, gdb_agent_op_names, gdb_agent_op_sizes,
16315	agent_expr, eval_result_type): Move to ax.h.
16316	(parse_agent_expr): Rename to ...
16317	(gdb_parse_agent_expr): ... this, make it non-static and move
16318	to ax.h.
16319	(unparse_agent_expr) Rename to ...
16320	(gdb_unparse_agent_expr): ... this, make it non-static and move
16321	to ax.h.
16322	(eval_agent_expr): Rename to ...
16323	(eval_tracepoint_agent_expr): ... this.
16324	(agent_mem_read, agent_mem_read_string, agent_tsv_read): Remove
16325	forward declarations.
16326	(add_tracepoint_action): Call gdb_parse_agent_expr (...).
16327	(agent_get_trace_state_variable_value): New function.
16328	(agent_set_trace_state_variable_value): New function.
16329	(cmd_qtdp): Call gdb_parse_agent_expr (...).
16330	(response_tracepoint): Call gdb_unparse_agent_expr (...).
16331	(do_action_at_tracepoint): Call eval_tracepoint_agent_expr (...).
16332	(condition_true_at_tracepoint): Likewise.
16333	(parse_agent_expr): Rename to ...
16334	(gdb_parse_agent_expr): ... this and move to ax.c.
16335	(unparse_agent_expr): Rename to ...
16336	(gdb_unparse_agent_expr): ... this and move to ax.c.
16337	(gdb_agent_op_name): Move to ax.c.
16338	(eval_agent_expr): Rename to ...
16339	(gdb_eval_agent_expr): ... this, use regcache passed as parameter
16340	and move to ax.c.
16341	(eval_tracepoint_agent_expr): New function.
16342	(agent_mem_read, agent_mem_read_string, agent_tsv_read): Make
16343	non-static.
16344	(current_insn_ptr, emit_error, struct bytecode_address): Move to
16345	ax.c.
16346	(emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul, emit_lsh,
16347	emit_rsh_signed, emit_rsh_unsigned, emit_ext, emit_log_not,
16348	emit_bit_and, emit_bit_or, emit_bit_xor, emit_bit_not, emit_equal,
16349	emit_less_signed, emit_less_unsigned, emit_ref, emit_if_goto,
16350	emit_goto, write_goto_address, emit_const, emit_reg, emit_pop,
16351	emit_stack, emit_zero_ext, emit_swap, emit_stack_adjust,
16352	emit_int_call_1, emit_void_call_2, emit_eq_goto, emit_ne_goto,
16353	emit_lt_goto, emit_ge_goto, emit_gt_goto, emit_le_goto): Move to ax.c.
16354	(get_get_tsv_func_addr, get_set_tsv_func_addr): New functions.
16355	(compile_bytecodes): Remove forward declaration.
16356	(is_goto_target): Move to ax.c.
16357	(compile_bytecodes): Move to ax.c and call
16358	agent_get_trace_state_variable_value (...) and
16359	agent_set_trace_state_variable_value (...).
16360
16361	* Makefile.in: Update ax.c and IPA dependencies.
16362
163632012-02-24  Pedro Alves  <palves@redhat.com>
16364
16365	* tracepoint.c (cmd_bigqtbuffer): Rename as ...
16366	(cmd_bigqtbuffer_circular): ... this.  Only handle
16367	'QTBuffer:circular:'.
16368	(handle_tracepoint_general_set): Adjust.
16369
163702012-02-16  Yao Qi  <yao@codesourcery.com>
16371
16372	* inferiors.c: Move code to ...
16373	* dll.c: .... here.  New.
16374	* server.h: Declare clear_dlls.
16375	* Makefile.in (SFILES): Add dll.c.
16376	(OBS): Add dll.o
16377	(dll.o): New rule.
16378
163792012-02-11  Yao Qi  <yao@codesourcery.com>
16380
16381	* server.c: (handle_monitor_command): Add a new parameter
16382	`own_buf'.
16383	(handle_query): Update caller.
16384
163852012-02-09  Joel Brobecker  <brobecker@adacore.com>
16386
16387	* configure.ac: Add readlink to AC_CHECK_FUNCS list.
16388	* configure, config.in: Regenerate.
16389	* hostio.c: Provide an alternate implementation if HAVE_READLINK
16390	is not defined.
16391
163922012-02-02  Pedro Alves  <palves@redhat.com>
16393
16394	Try SIGKILL first, then PTRACE_KILL.
16395	* linux-low.c (linux_kill_one_lwp): New.
16396	(linux_kill_one_lwp): Rename to ...
16397	(kill_one_lwp_callback): ... this.  Use the new
16398	linux_kill_one_lwp.
16399
164002012-02-02  Pedro Alves  <palves@redhat.com>
16401
16402	* tracepoint.c (cmd_qtminftpilen): Return 0 if there's no current
16403	inferior.
16404
164052012-01-27  Pedro Alves  <palves@redhat.com>
16406
16407	* linux-low.c (linux_child_pid_to_exec_file): Delete.
16408	(elf_64_file_p): Make static.
16409	(linux_pid_exe_is_elf_64_file): New.
16410	* linux-low.h (linux_child_pid_to_exec_file, elf_64_file_p):
16411	Delete declarations.
16412	(linux_pid_exe_is_elf_64_file): Declare.
16413	* linux-x86-low.c (x86_arch_setup): Use
16414	linux_pid_exe_is_elf_64_file.
16415
164162012-01-25  Jan Kratochvil  <jan.kratochvil@redhat.com>
16417
16418	* linux-low.c (linux_wait_for_event_1): Rename to ...
16419	(linux_wait_for_event): ... here and merge it with former
16420	linux_wait_for_event - new variable wait_ptid, use it.
16421	(linux_wait_for_event): Remove - merge it to linux_wait_for_event_1.
16422
164232012-01-23  Pedro Alves  <palves@redhat.com>
16424
16425	* server.c (main): Avoid yet another case of infinite loop while
16426	detaching/killing after a longjmp.
16427
164282012-01-20  Jan Kratochvil  <jan.kratochvil@redhat.com>
16429
16430	Code cleanup.
16431	* linux-low.c (linux_wait_for_event_1): Use ptid_is_pid.
16432
164332012-01-20  Ulrich Weigand  <ulrich.weigand@linaro.org>
16434
16435	* hostio.c (handle_readlink): New function.
16436	(handle_vFile): Call it to handle "vFile:readlink" packets.
16437
164382012-01-20  Pedro Alves  <palves@redhat.com>
16439	    Ulrich Weigand  <ulrich.weigand@linaro.org>
16440
16441	* server.c (handle_v_requests): Only support vAttach and vRun to
16442	start multiple processes when in extended protocol mode.
16443
164442012-01-17  Pedro Alves  <palves@redhat.com>
16445
16446	* tracepoint.c (initialize_tracepoint): Use mmap instead of
16447	memalign plus mprotect to allocate the scratch buffer.
16448
164492012-01-13  Pedro Alves  <palves@redhat.com>
16450
16451	* server.c (attach_inferior): Clear `cont_thread'.
16452
164532012-01-13  Pedro Alves  <palves@redhat.com>
16454
16455	* server.c (main): Avoid infinite loop while detaching/killing
16456	after a longjmp.
16457
164582012-01-09  Doug Evans  <dje@google.com>
16459
16460	* server.c (start_inferior): Set last_ptid in --wrapper case.
16461
164622012-01-06  Yao Qi  <yao@codesourcery.com>
16463
16464	* tracepoint.c [IN_PROCESS_AGENT] (debug_threads): Macro
16465	defined.
16466	[IN_PROCESS_AGENT] (debug_agent): New global variable.
16467
164682012-01-04  Yao Qi  <yao@codesourcery.com>
16469
16470	* tracepoint.c (cmd_qtdp): Print debug message
16471	for static tracepoint.
16472
164732012-01-04  Yao Qi  <yao@codesourcery.com>
16474
16475	* tracepoint.c (trace_vdebug): Differentiate debug message
16476	between gdbserver and IPA.
16477
164782012-01-03  Yao Qi  <yao@codesourcery.com>
16479
16480	* tracepoint.c (tracepoint_was_hit): Don't collect for
16481	static tracepoint.
16482
164832012-01-02  Joel Brobecker  <brobecker@adacore.com>
16484
16485	* terminal.h: Reformat copyright header.
16486
164872012-01-02  Joel Brobecker  <brobecker@adacore.com>
16488
16489	* server.c (gdbserver_version): Update copyright year.
16490	* gdbreplay.c (gdbreplay_version): Likewise.
16491
164922011-12-18  Jan Kratochvil  <jan.kratochvil@redhat.com>
16493
16494	* linux-low.c (linux_create_inferior): Put empty if clause for write.
16495
16496	Revert:
16497	2011-12-18  Hui Zhu  <teawater@gmail.com>
16498	* linux-low.c (linux_create_inferior): Save return value to ret.
16499
165002011-12-18  Hui Zhu  <teawater@gmail.com>
16501
16502	* linux-low.c (linux_create_inferior): Save return value to ret.
16503
165042011-12-16  Doug Evans  <dje@google.com>
16505
16506	* linux-low.c (linux_create_inferior): If stdio connection,
16507	redirect stdin from /dev/null, stdout to stderr.
16508	* remote-utils.c (remote_is_stdio): New static global.
16509	(remote_connection_is_stdio): New function.
16510	(remote_prepare): Handle stdio connection.
16511	(remote_open): Ditto.
16512	(remote_close): Don't close stdin for stdio connections.
16513	(read_prim,write_prim): New functions.  Replace all calls to
16514	read/write to these.
16515	* server.c (main): Watch for "-" argument.  Move call to
16516	remote_prepare before start_inferior.
16517	* server.h (STDIO_CONNECTION_NAME): New macro.
16518	(remote_connection_is_stdio): Declare.
16519
16520	* remote-utils.c (prepare_resume_reply): Remove extraneous \n
16521	in debugging output.
16522
165232011-12-15  Yao Qi  <yao@codesourcery.com>
16524
16525	* tracepoint.c: Include sys/syscall.h.
16526	(gdb_ust_thread): Remove preprocessor conditional.
16527
165282011-12-14  Pedro Alves  <pedro@codesourcery.com>
16529
16530	* linux-low.c (linux_detach_one_lwp): Call
16531	the_low_target.prepare_to_resume before detaching.
16532
165332011-12-14  Yao Qi  <yao@codesourcery.com>
16534
16535	* tracepoint.c (gdb_ust_thread): Don't ignore return value
16536	of write.
16537
165382011-12-14  Yao Qi  <yao@codesourcery.com>
16539
16540	* i386-low.c (i386_low_stopped_data_address): Initialize local
16541	variable `control'.
16542
165432011-12-13  Pedro Alves  <pedro@codesourcery.com>
16544
16545	PR remote/13492
16546
16547	* i386-low.c (i386_low_stopped_data_address): Avoid fetching
16548	DR_CONTROL unless necessary.  Extend comments.
16549	* linux-x86-low.c (x86_linux_prepare_to_resume): Don't write to
16550	DR0-3 if not used.  If any watchpoint was set, clear DR_STATUS.
16551
165522011-12-13  Yao Qi  <yao@codesourcery.com>
16553
16554	* tracepoint.c (trace_buffer_alloc): Replace magic numbers with
16555	macros.
16556	(upload_fast_traceframes, upload_fast_traceframes): Likewise.
16557
165582011-12-08  Jan Kratochvil  <jan.kratochvil@redhat.com>
16559
16560	* linux-low.c (linux_kill): Skip PTRACE_KILL if LWP does not exist.
16561	Print new debug message for such case.
16562
165632011-12-06  Jan Kratochvil  <jan.kratochvil@redhat.com>
16564
16565	Fix overlapping memcpy.
16566	* mem-break.c (set_raw_breakpoint_at): New variable buf.  Use it for
16567	the read_inferior_memory transfer.
16568	(delete_fast_tracepoint_jump): New variable buf.  Use it for the
16569	write_inferior_memory transfer.
16570	(set_fast_tracepoint_jump): New variable buf.  Use it for the
16571	read_inferior_memory and write_inferior_memory transfers.
16572	(uninsert_fast_tracepoint_jumps_at, reinsert_fast_tracepoint_jumps_at)
16573	(delete_raw_breakpoint, uninsert_raw_breakpoint): New variable buf.
16574	Use it for the write_inferior_memory transfer.
16575	(check_mem_read, check_mem_write): New gdb_asserts for overlapping
16576	buffers.
16577
165782011-12-06  Maciej W. Rozycki  <macro@codesourcery.com>
16579
16580	* linux-low.c (fetch_register, store_register): Make code
16581	consistent, fix formatting.
16582
165832011-12-06  Maciej W. Rozycki  <macro@codesourcery.com>
16584
16585	* linux-low.c (usr_store_inferior_registers): Factor out code
16586	to handle individual registers into...
16587	(store_register): ... this new function.
16588
165892011-12-06  Ulrich Weigand  <uweigand@de.ibm.com>
16590
16591	* Makefile.in (s390-linux32v1.o, s390-linux32v1.c): New rules.
16592	(s390-linux32v2.o, s390-linux32v2.c): Likewise.
16593	(s390-linux64v1.o, s390-linux64v1.c): Likewise.
16594	(s390-linux64v2.o, s390-linux64v2.c): Likewise.
16595	(s390x-linux64v1.o, s390x-linux64v1.c): Likewise.
16596	(s390x-linux64v2.o, s390x-linux64v2.c): Likewise.
16597	* configure.srv [s390*-*-linux*] (srv_regobj): Add new objects.
16598	(srv_xmlfiles): Add new XML files.
16599
16600	* linux-s390-low.c: Include "elf/common.h", <sys/ptrace.h>,
16601	and <sys/uio.h>.
16602	(PTRACE_GETREGSET, PTRACE_SETREGSET): Define if undefined.
16603	(init_registers_s390_linux32v1): Add prototype.
16604	(init_registers_s390_linux32v2): Likewise.
16605	(init_registers_s390_linux64v1): Likewise.
16606	(init_registers_s390_linux64v2): Likewise.
16607	(init_registers_s390x_linux64v1): Likewise.
16608	(init_registers_s390x_linux64v2): Likewise.
16609	(s390_num_regs): Increment to 52.
16610	(s390_regmap): Add orig_r2 register.
16611	(s390_num_regs_3264): Increment to 68.
16612	(s390_regmap_3264): Add orig_r2 register.
16613	(s390_collect_ptrace_register): Handle orig_r2 register.
16614	(s390_supply_ptrace_register): Likewise.
16615	(s390_fill_last_break): New function.
16616	(s390_store_last_break): Likewise.
16617	(s390_fill_system_call): New function.
16618	(s390_store_system_call): Likewise.
16619	(target_regsets): Handle NT_S390_LAST_BREAK and NT_S390_SYSTEM_CALL
16620	register sets.
16621	(s390_check_regset): New function.
16622	(s390_arch_setup): Check for presence of NT_S390_LAST_BREAK and
16623	NT_S390_SYSTEM_CALL regsets and use appropriate description.
16624	Update target_regsets for available register sets.
16625
166262011-12-02  Paul Pluzhnikov  <ppluzhnikov@google.com>
16627	    Jan Kratochvil  <jan.kratochvil@redhat.com>
16628
16629	* linux-low.c (get_phdr_phnum_from_proc_auxv, get_dynamic, get_r_debug)
16630	(read_one_ptr, struct link_map_offsets, linux_qxfer_libraries_svr4):
16631	New.
16632	(struct linux_target_ops): Install linux_qxfer_libraries_svr4.
16633	* linux-low.h (struct process_info_private): New member r_debug.
16634	* server.c (handle_qxfer_libraries): Call
16635	the_target->qxfer_libraries_svr4.
16636	(handle_qxfer_libraries_svr4): New function.
16637	(qxfer_packets): New entry "libraries-svr4".
16638	(handle_query): Check QXFER_LIBRARIES_SVR4 and report libraries-svr4.
16639	* target.h (struct target_ops): New member qxfer_libraries_svr4.
16640	* remote.c (remote_xfer_partial): Call add_packet_config_cmd for
16641	PACKET_qXfer_libraries_svr4.
16642
166432011-11-30  Ulrich Weigand  <uweigand@de.ibm.com>
16644
16645	* linux-s390-low.c (s390_collect_ptrace_register): Fully convert
16646	PSW address/mask between 8-byte and 16-byte formats.
16647	(s390_supply_ptrace_register): Likewise.
16648	(s390_get_pc, s390_set_pc): 4-byte PSW address always includes
16649	basic addressing mode bit.
16650
166512011-11-24  Stan Shebs  <stan@codesourcery.com>
16652
16653	* tracepoint.c (cmd_qtstatus): Use plongest instead of %llx.
16654
166552011-11-17  Stan Shebs  <stan@codesourcery.com>
16656
16657	* tracepoint.c (struct tracepoint): New field traceframe_usage.
16658	(tracing_start_time): New global.
16659	(tracing_stop_time): New global.
16660	(tracing_user_name): New global.
16661	(tracing_notes): New global.
16662	(tracing_stop_note): New global.
16663	(cmd_qtstart): Set traceframe_usage, start_time.
16664	(stop_tracing): Set stop_time.
16665	(cmd_qtstatus): Report additional status.
16666	(cmd_qtp): New function.
16667	(handle_tracepoint_query): Call it.
16668	(cmd_qtnotes): New function.
16669	(handle_tracepoint_general_set): Call it.
16670	(get_timestamp): Rename from tsv_get_timestamp.
16671
166722011-11-14  Stan Shebs  <stan@codesourcery.com>
16673	    Kwok Cheung Yeung  <kcy@codesourcery.com>
16674
16675	* linux-x86-low.c (small_jump_insn): New.
16676	(i386_install_fast_tracepoint_jump_pad): Add arguments for
16677	trampoline and error message, build a trampoline and issue a small
16678	jump instruction to it.
16679	(x86_install_fast_tracepoint_jump_pad): Add arguments for
16680	trampoline and error message.
16681	(x86_get_min_fast_tracepoint_insn_len): New.
16682	(the_low_target): Add call to x86_get_min_fast_tracepoint_insn_len.
16683	* linux-low.h (struct linux_target_ops): Add arguments to
16684	install_fast_tracepoint_jump_pad operation, add new operation.
16685	* linux-low.c (linux_install_fast_tracepoint_jump_pad): Add
16686	arguments.
16687	(linux_get_min_fast_tracepoint_insn_len): New function.
16688	(linux_target_op): Add new operation.
16689	* tracepoint.c (gdb_trampoline_buffer): New IPA variable.
16690	(gdb_trampoline_buffer_end): Ditto.
16691	(gdb_trampoline_buffer_error): Ditto.
16692	(struct ipa_sym_addresses): Add fields for new IPA variables.
16693	(symbol_list): Add entries for new IPA variables.
16694	(struct tracepoint): Add fields to hold the address range of the
16695	trampoline used by the tracepoint.
16696	(trampoline_buffer_head): New static variable.
16697	(trampoline_buffer_tail): Ditto.
16698	(claim_trampoline_space): New function.
16699	(have_fast_tracepoint_trampoline_buffer): New function.
16700	(clone_fast_tracepoint): Fill in trampoline fields of tracepoint
16701	structure.
16702	(install_fast_tracepoint): Ditto, also add error buffer argument.
16703	(cmd_qtminftpilen): New function.
16704	(handle_tracepoint_query): Add response to qTMinFTPILen packet.
16705	(fast_tracepoint_from_trampoline_address): New function.
16706	(fast_tracepoint_collecting): Handle trampoline as part of jump
16707	pad space.
16708	(set_trampoline_buffer_space): New function.
16709	(initialize_tracepoint): Initialize new IPA variables.
16710	* target.h (struct target_ops): Add arguments to
16711	install_fast_tracepoint_jump_pad operation, add new
16712	get_min_fast_tracepoint_insn_len operation.
16713	(target_get_min_fast_tracepoint_insn_len): New.
16714	(install_fast_tracepoint_jump_pad): Add arguments.
16715	* server.h (IPA_BUFSIZ): Define.
16716	* linux-i386-ipa.c: Include extra header files.
16717	(initialize_fast_tracepoint_trampoline_buffer): New function.
16718	(initialize_low_tracepoint): Call it.
16719	* server.h (set_trampoline_buffer_space): Declare.
16720	(claim_trampoline_space): Ditto.
16721	(have_fast_tracepoint_trampoline_buffer): Ditto.
16722
167232011-11-14  Yao Qi  <yao@codesourcery.com>
16724
16725	* server.c (handle_query): Handle InstallInTrace for qSupported.
16726	* tracepoint.c (add_tracepoint): Sort list.
16727	(install_tracepoint, download_tracepoint): New.
16728	(cmd_qtdp): Call them to install and download tracepoints.
16729	(sort_tracepoints): Removed.
16730	(cmd_qtstart): Update.
16731
167322011-11-14  Yao Qi  <yao@codesourcery.com>
16733
16734	* mem-break.c (inc_ref_fast_tracepoint_jump): New.
16735	* mem-break.h: Declare.
16736	* tracepoint.c (cmd_qtstart): Move some code to ...
16737	(clone_fast_tracepoint, install_fast_tracepoint): ... here.
16738	New.
16739	(download_tracepoints): Move some code to ...
16740	(download_tracepoint_1): ... here.  New.
16741
167422011-11-08  Yao Qi  <yao@codesourcery.com>
16743
16744	* remote-utils.c (relocate_instruction): A comment fix.
16745
167462011-11-07  Joel Brobecker  <brobecker@adacore.com>
16747
16748	* win32-i386-low.c (dr_status_mirror, dr_control_mirror): Delete.
16749	(i386_dr_low_get_control, i386_dr_low_get_status): Use
16750	dr_status_mirror and dr_control_mirror from debug_reg_state.
16751	(i386_dr_low_get_status): Use debug_reg_state.dr_status_mirror
16752	(i386_initial_stuff): Remove use of deleted globals.
16753	(i386_get_thread_context, i386_set_thread_context,
16754	i386_thread_added): Use dr_status_mirror and dr_control_mirror
16755	from debug_reg_state.
16756
167572011-11-05  Yao Qi  <yao@codesourcery.com>
16758
16759	* tracepoint.c (gdb_collect): Loop over tracepoints of same
16760	address as TPOINT's.
16761
167622011-11-02  Stan Shebs  <stan@codesourcery.com>
16763
16764	* tracepoint.c (agent_mem_read_string): New function.
16765	(eval_agent_expr): Call it for tracenz.
16766	* server.c (handle_query): Report support for tracenz.
16767
167682011-11-02  Yao Qi  <yao@codesourcery.com>
16769
16770	* tracepoint.c (cmd_qtstart): Remove unused local variables.
16771
167722011-11-02  Yao Qi  <yao@codesourcery.com>
16773
16774	* target.h: Fix a typo in comment.
16775
167762011-10-31  Pedro Alves  <pedro@codesourcery.com>
16777
16778	* mem-break.c (check_mem_write): Add `myaddr' parameter.  Don't
16779	clobber the breakpoints' shadows with fast tracepoint jumps.
16780	* mem-break.h (check_mem_write): Add `myaddr' parameter.
16781	* target.c (write_inferior_memory): Also pass MYADDR down to
16782	check_mem_write.
16783
167842011-10-07  Ulrich Weigand  <ulrich.weigand@linaro.org>
16785
16786	* configure.ac: Check support for personality routine.
16787	* configure: Regenerate.
16788	* config.in: Likewise.
16789	* linux-low.c: Include <sys/personality.h>.
16790	Define ADDR_NO_RANDOMIZE if necessary.
16791	(linux_create_inferior): Disable address space randomization when
16792	forking inferior, if requested.
16793	(linux_supports_disable_randomization): New function.
16794	(linux_target_ops): Install it.
16795	* server.h (disable_randomization): Declare.
16796	* server.c (disable_randomization): New global variable.
16797	(handle_general_set): Handle QDisableRandomization.
16798	(handle_query): Likewise for qSupported.
16799	(main): Support --disable-randomization and --no-disable-randomization
16800	command line arguments.
16801	* target.h (struct target_ops): Add supports_disable_randomization.
16802	(target_supports_disable_randomization): New macro.
16803
168042011-09-29  Mike Frysinger  <vapier@gentoo.org>
16805
16806	* linux-low.c (target_loadseg): Add defined PTRACE_GETFDPIC to the
16807	ifdef check.
16808	[PT_GETDSBT] (target_loadmap): Wrap in a defined PT_GETDSBT check.
16809	[!PT_GETDSBT] (target_loadmap): New definition.
16810	(LINUX_LOADMAP, LINUX_LOADMAP_EXEC, LINUX_LOADMAP_INTERP): Define.
16811	(linux_read_loadmap): Change PTRACE_GETDSBT_EXEC to
16812	LINUX_LOADMAP_EXEC, PTRACE_GETDSBT_INTERP to LINUX_LOADMAP_INTERP,
16813	and PT_GETDSBT to LINUX_LOADMAP.
16814	[!PT_GETDSBT] (linux_read_loadmap): Define to NULL.
16815	(linux_target_ops): Delete unnecessary ifdef PT_GETDSBT check.
16816
168172011-09-21  Ulrich Weigand  <ulrich.weigand@linaro.org>
16818
16819	* linux-arm-low.c (struct arm_linux_hwbp_cap): Remove.
16820	(arm_linux_hwbp_cap): New static variable.
16821	(arm_linux_get_hwbp_cap): Replace by ...
16822	(arm_linux_init_hwbp_cap): ... this new function.
16823	(arm_linux_get_hw_breakpoint_count): Use arm_linux_hwbp_cap.
16824	(arm_linux_get_hw_watchpoint_count): Likewise.
16825	(arm_linux_get_hw_watchpoint_max_length): Likewise.
16826	(arm_arch_setup): Call arm_linux_init_hwbp_cap.
16827	(arm_prepare_to_resume): Use perror_with_name instead of error.
16828
168292011-09-21  Ulrich Weigand  <ulrich.weigand@linaro.org>
16830
16831	* linux-arm-low.c: Include <signal.h>.
16832	(PTRACE_GETHBPREGS, PTRACE_SETHBPREGS): Define if necessary.
16833	(struct arm_linux_hwbp_cap): New data type.
16834	(arm_hwbp_type, arm_hwbp_control_t): New typedefs.
16835	(struct arm_linux_hw_breakpoint): New data type.
16836	(MAX_BPTS, MAX_WPTS): Define.
16837	(struct arch_process_info, struct arch_lwp_info): New data types.
16838	(arm_linux_get_hwbp_cap): New function.
16839	(arm_linux_get_hw_breakpoint_count): Likewise.
16840	(arm_linux_get_hw_watchpoint_count): Likewise.
16841	(arm_linux_get_hw_watchpoint_max_length): Likewise.
16842	(arm_hwbp_control_initialize): Likewise.
16843	(arm_hwbp_control_is_enabled): Likewise.
16844	(arm_hwbp_control_is_initialized): Likewise.
16845	(arm_hwbp_control_disable): Likewise.
16846	(arm_linux_hw_breakpoint_equal): Likewise.
16847	(arm_linux_hw_point_initialize): Likewise.
16848	(struct update_registers_data): New data structure.
16849	(update_registers_callback: New function.
16850	(arm_insert_point): Likewise.
16851	(arm_remove_point): Likewise.
16852	(arm_stopped_by_watchpoint): Likewise.
16853	(arm_stopped_data_address): Likewise.
16854	(arm_new_process): Likewise.
16855	(arm_new_thread): Likewise.
16856	(arm_prepare_to_resume): Likewise.
16857	(the_low_target): Register arm_insert_point, arm_remove_point,
16858	arm_stopped_by_watchpoint, arm_stopped_data_address, arm_new_process,
16859	arm_new_thread, and arm_prepare_to_resume.
16860
168612011-09-15  Stan Shebs  <stan@codesourcery.com>
16862
16863	* server.h (struct emit_ops): Add compare-goto fields.
16864	* tracepoint.c (gdb_agent_op_sizes): New table.
16865	(emit_eq_goto): New function.
16866	(emit_ne_goto): New function.
16867	(emit_lt_goto): New function.
16868	(emit_le_goto): New function.
16869	(emit_gt_goto): New function.
16870	(emit_ge_goto): New function.
16871	(is_goto_target): New function.
16872	(compile_bytecodes): Recognize special cases of compare-goto
16873	combinations and call specialized emitters for them.
16874	* linux-x86-low.c (amd64_emit_eq_goto): New function.
16875	(amd64_emit_ne_goto): New function.
16876	(amd64_emit_lt_goto): New function.
16877	(amd64_emit_le_goto): New function.
16878	(amd64_emit_gt_goto): New function.
16879	(amd64_emit_ge_goto): New function.
16880	(amd64_emit_ops): Add the new functions.
16881	(i386_emit_eq_goto): New function.
16882	(i386_emit_ne_goto): New function.
16883	(i386_emit_lt_goto): New function.
16884	(i386_emit_le_goto): New function.
16885	(i386_emit_gt_goto): New function.
16886	(i386_emit_ge_goto): New function.
16887	(i386_emit_ops): Add the new functions.
16888
168892011-09-08  Stan Shebs  <stan@codesourcery.com>
16890
16891	* linux-x86-low.c (i386_emit_prologue): Save %ebx.
16892	(i386_emit_epilogue): Restore %ebx.
16893
168942011-08-31  Jie Zhang  <jzhang918@gmail.com>
16895
16896	* server.c (step_thread): Remove definition.
16897	(process_serial_event): Don't handle Hs.
16898	* server.h (step_thread): Remove declaration.
16899	* target.c (set_desired_inferior): Remove use of step_thread.
16900
169012011-08-24  Luis Machado  <lgustavo@codesourcery.com>
16902
16903	* linux-low.c: Include linux-procfs.h.
16904	(linux_attach_lwp_1): Update comments.
16905	(linux_attach): Scan for existing threads when attaching to a
16906	process that is the tgid.
16907	* Makefile.in: Update dependencies.
16908
169092011-08-24  Luis Machado  <lgustavo@codesourcery.com>
16910
16911	* configure.srv: Add linux-procfs.o dependencies.
16912
169132011-08-14  Yao Qi  <yao@codesourcery.com>
16914
16915	* target.h (struct target_ops): Fix indent.
16916	* win32-low.c (win32_target_ops): Fix comment.
16917
169182011-08-14  Andrew Jenner  <andrew@codesourcery.com>
16919	    Yao Qi  <yao@codesourcery.com>
16920
16921	* Makefile.in (clean): Remove tic6x-*.c files.
16922	(linux-tic6x-low.o, tic6x-c62x-linux.o, tic6x-c64x-linux.o): New rules.
16923	(tic6x-c64xp-linux.o, tic6x-c62x-linux.c, tic6x-c64x-linux.c): Likewise.
16924	(tic6x-c64xp-linux.c): Likewise.
16925	* configure.srv: Add support for tic6x-*-uclinux.
16926	* linux-tic6x-low.c: New.
16927	* linux-low.c (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define.
16928
169292011-08-14  Andrew Stubbs <ams@codesourcery.com>
16930	    Yao Qi  <yao@codesourcery.com>
16931
16932	* target.h (struct target_ops): Add read_loadmap.
16933	* linux-low.c (struct target_loadseg): New type.
16934	(struct target_loadmap): New type.
16935	(linux_read_loadmap): New function.
16936	(linux_target_ops): Add linux_read_loadmap.
16937	* server.c (handle_query): Support qXfer:fdpic:read packet.
16938	* win32-low.c (win32_target_ops): Initialize field `read_loadmap'
16939	to NULL.
16940
169412011-08-05  Eli Zaretskii  <eliz@gnu.org>
16942
16943	* win32-low.c: Include <stdint.h>.
16944
169452011-07-22  Pedro Alves  <pedro@codesourcery.com>
16946
16947	* i386-low.c (i386_insert_aligned_watchpoint): Don't pass the info
16948	to the inferior here.
16949	(i386_remove_aligned_watchpoint): Ditto.
16950	(i386_handle_nonaligned_watchpoint): Return immediate on fail to
16951	fit part of the watchpoint in the debug registers.
16952	(i386_update_inferior_debug_regs): New.
16953	(i386_low_insert_watchpoint): Work on a local mirror of the debug
16954	registers, and only update the inferior on success.
16955	(i386_low_remove_watchpoint): Ditto.
16956
169572011-07-22  Kwok Cheung Yeung  <kcy@codesourcery.com>
16958
16959	* linux-low.c (compare_ints, unique, list_threads, show_process,
16960	linux_core_of_thread): Delete.
16961	(linux_target_ops): Change linux_core_of_thread to
16962	linux_common_core_of_thread.
16963	(linux_qxfer_osdata): Defer to linux_common_xfer_osdata.
16964	* utils.c (malloc_failure): Change type of argument.
16965	(xmalloc, xrealloc, xcalloc, xsnprintf): Delete.
16966	* Makefile.in (SFILES): Add common/common-utils.c, common/xml-utils.c,
16967	common/linux-osdata.c, common/ptid.c and common/buffer.c.
16968	(OBS): Add xml-utils.o, common-utils.o, ptid.o and buffer.o.
16969	(IPA_OBJS): Add common-utils-ipa.o.
16970	(ptid_h, linux_osdata_h): New macros.
16971	(server_h): Add common/common-utils.h, common/xml-utils.h,
16972	common/buffer.h, common/gdb_assert.h, common/gdb_locale.h and
16973	common/ptid.h.
16974	(common-utils-ipa.o, common-utils.o, xml-utils.o, linux-osdata.o,
16975	ptid.o, buffer.o): New rules.
16976	(linux-low.o): Add common/linux-osdata.h as a dependency.
16977	* configure.srv (srv_tgtobj): Add linux-osdata.o to Linux targets.
16978	* configure.ac: Add AC_HEADER_DIRENT check.
16979	* config.in: Regenerate.
16980	* configure: Regenerate.
16981	* remote-utils.c (xml_escape_text): Delete.
16982	(buffer_grow, buffer_free, buffer_init, buffer_finish,
16983	buffer_xml_printf): Move to common/buffer.c.
16984	* server.c (main): Remove call to initialize_inferiors.
16985	* server.h (struct ptid, ptid_t, minus_one_ptid, null_ptid,
16986	ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp, ptid_get_tid,
16987	ptid_equal, ptid_is_pid, initialize_inferiors, xml_escape_text,
16988	internal_error, gdb_assert, gdb_assert_fail): Delete.
16989	(struct buffer, buffer_grow, buffer_free, buffer_init, buffer_finish,
16990	buffer_xml_printf, buffer_grow_str, buffer_grow_str0): Move to
16991	common/buffer.h.
16992	* inferiors.c (null_ptid, minus_one_ptid, ptid_build, pid_to_ptid,
16993	ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal, ptid_is_pid,
16994	initialize_inferiors): Delete.
16995
169962011-07-20  Pedro Alves  <pedro@codesourcery.com>
16997
16998	* tracepoint.c (tracepoint_look_up_symbols): Return upon the first
16999	symbol error.
17000
170012011-05-31  Pedro Alves  <pedro@codesourcery.com>
17002
17003	* linux-x86-low.c (i386_dr_low_get_addr): Fix off by one in
17004	assertion.
17005	* win32-i386-low.c (i386_dr_low_get_addr): Ditto.
17006
170072011-05-26  Yao Qi  <yao@codesourcery.com>
17008
17009	* Makefile.in (thread-db.o): Track dependence to
17010	common/gdb_thread_db.h.
17011	* thread-db.c: include gdb_thread_db.h from right place.
17012
170132011-05-16  Adrian Cornish  <gnu@bluedreamer.com>
17014
17015	* linux-i386-ipa.c (supply_static_tracepoint_registers): Pass
17016	__FILE__ and __LINE__ to internal_error.
17017
170182011-05-13  Doug Evans  <dje@google.com>
17019
17020	* thread-db.c (try_thread_db_load_from_sdir): New function.
17021	(try_thread_db_load_from_dir): New function.
17022	(thread_db_load_search): Handle $sdir, ignore $pdir.
17023	Remove trying of system directories if search of
17024	libthread-db-search-path fails,	that is now done via $sdir.
17025
170262011-05-12  Kwok Cheung Yeung  <kcy@codesourcery.com>
17027
17028	* server.c (handle_query): Add EnableDisableTracepoints to the list
17029	of supported features.
17030	* tracepoint.c (clear_installed_tracepoints): Uninstall disabled
17031	tracepoints.
17032	(cmd_qtenable_disable): New.
17033	(cmd_qtstart): Install tracepoints even if disabled.
17034	(handle_tracepoint_general_set): Add call to cmd_qtenable_disable on
17035	receiving a QTEnable or QTDisable packet.
17036	(gdb_collect): Skip data collection if fast tracepoint is disabled.
17037	(ust_marker_to_static_tracepoint): Do not ignore disabled static
17038	tracepoints.
17039	(gdb_probe): Skip data collection if static tracepoint is disabled.
17040
170412011-05-10  Doug Evans  <dje@google.com>
17042
17043	* thread-db.c (thread_db_handle_monitor_command): Handle elided path.
17044
170452011-05-04  Doug Evans  <dje@google.com>
17046
17047	* linux-low.c (linux_join): Skip process lookup.
17048	* spu-low.c (spu_join): Ditto.
17049	* server.c (join_inferiors_callback): Delete.
17050	(process_serial_event): For 'D' packet (detach) call join_inferior
17051	directly.
17052
170532011-05-04  Joseph Myers  <joseph@codesourcery.com>
17054
17055	* README: Don't mention xscale*-*-linux*.
17056	* configure.srv (xscale*-*-linux*): Don't handle target.
17057
170582011-04-27  Nathan Froyd  <froydnj@codesourcery.com>
17059
17060	* linux-x86-low.c (amd64_emit_const): Call memcpy instead of
17061	casting pointers.
17062	(amd64_emit_reg, amd64_emit_int_call_1, amd64_emit_void_call_2):
17063	(i386_emit_const, i386_emit_reg, i386_emit_int_call_1):
17064	(i386_emit_void_call_2): Likewise.
17065
170662011-04-26  Yao Qi  <yao@codesourcery.com>
17067
17068	* linux-low.c: Move common macros to linux-ptrace.h.
17069	Include linux-ptrace.h.
17070	* Makefile.in (linux_ptrace_h): New.
17071	(linux-low.o): Depends on linux-ptrace.h.
17072
170732011-04-24  Jan Kratochvil  <jan.kratochvil@redhat.com>
17074
17075	* remote-utils.c (handle_accept_event): Close LISTEN_DESC only if
17076	RUN_ONCE.  Comment for the LISTEN_DESC delete_file_handler call.
17077	(remote_prepare): New function with most of the TCP code from ...
17078	(remote_open): ... here.  Detect PORT here unconditionally.  Move also
17079	setting transport_is_reliable.
17080	* server.c (run_once): New variable.
17081	(gdbserver_usage): Document it.
17082	(main): Set run_once for `--once'.  Call remote_prepare.  Exit after
17083	the first run if RUN_ONCE.
17084	* server.h (run_once, remote_prepare): New declarations.
17085
170862011-04-19  Tom Tromey  <tromey@redhat.com>
17087
17088	* win32-low.c (handle_load_dll): Remove duplicate "the".
17089
170902011-04-07  Pierre Muller  <muller@ics.u-strasbg.fr>
17091
17092	Remove support for old Cygwin 1.5 versions.
17093	* win32-low.c (win32_create_inferior): Use new cygwin_path_list
17094	function to avoid warning.
17095	(win32_add_one_solib): Use cygwin_conv_path function to avoid
17096	warning.
17097
170982011-03-18  Pierre Muller  <muller@ics.u-strasbg.fr>
17099
17100	* gdbserver/server.h (Macro _): Define it if not available.
17101
171022011-03-14  Michael Snyder  <msnyder@vmware.com>
17103
17104	* hostio.c (handle_close): Remove unnecessary null test.
17105
171062011-03-10  Joel Brobecker  <brobecker@adacore.com>
17107
17108	* Makefile.in (maintainer-clean realclean distclean): Remove
17109	"make ...  subdir_do" command.
17110
171112011-03-10  Michael Snyder  <msnyder@vmware.com>
17112
17113	* tracepoint.c (tracepoint_finish_step): Fix loop variable.
17114
17115	* server.c (handle_v_run): Free alloced buffer on early return.
17116
171172011-03-09  Yao Qi  <yao@codesourcery.com>
17118
17119	Revert:
17120	2011-03-04  Yao Qi  <yao@codesourcery.com>
17121
17122	* Makefile.in: Remove GNU make feature --directory.
17123
17124	2011-03-05  Yao Qi  <yao@codesourcery.com>
17125
17126	* Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
17127	(subdir_do): New make target.  Copied from gdb/Makefile.
17128	(maintainer-clean, realclean, distclean, clean): Call corresponding
17129	make targets in common/Makefile.
17130
17131	2011-02-11  Yao Qi  <yao@codesourcery.com>
17132
17133	* configure.ac: Call AC_PROG_RANLIB.
17134	* Makefile.in: Remove signals.o from OBS.  Link libcommon.a.
17135	* configure: Regenerate.
17136
171372011-03-07  Jan Kratochvil  <jan.kratochvil@redhat.com>
17138
17139	* remote-utils.c (putpkt_binary_1): Calculate BUF2 size dynamically.
17140
171412011-03-06  Yao Qi  <yao@codesourcery.com>
17142
17143	* Makefile.in (REQUIRED_SUBDIRS): Remove $(LIBCOMMON_DIR).
17144
171452011-03-05  Yao Qi  <yao@codesourcery.com>
17146
17147	* Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
17148	(subdir_do): New make target.  Copied from gdb/Makefile.
17149	(maintainer-clean, realclean, distclean, clean): Call corresponding
17150	make targets in common/Makefile.
17151
171522011-03-04  Yao Qi  <yao@codesourcery.com>
17153
17154	* Makefile.in: Remove GNU make feature --directory.
17155
171562011-03-04  Michael Snyder  <msnyder@vmware.com>
17157
17158	* server.c (queue_stop_reply): Call xmalloc not malloc.
17159
171602011-03-02  Michael Snyder  <msnyder@vmware.com>
17161
17162	* linux-arm-low.c (arm_arch_setup): Replace malloc with xmalloc.
17163
171642011-02-28  Michael Snyder  <msnyder@vmware.com>
17165
17166	* tracepoint.c (cmd_qtv): Discard unused value 'packet'.
17167	(cmd_qtframe): Ditto.
17168	(cmd_qtbuffer): Ditto.
17169	(cmd_bigqtbuffer): Ditto.
17170
17171	* utils.c (decimal2str): Initialize 'width' to nine, then
17172	don't mess with it.
17173
171742011-02-28  Ulrich Weigand  <uweigand@de.ibm.com>
17175
17176	* hostio.c (require_data): Free *data, not data.
17177
171782011-02-28  Jan Kratochvil  <jan.kratochvil@redhat.com>
17179
17180	* hostio.c (require_data): Use free, not xfree.
17181
171822011-02-27  Michael Snyder  <msnyder@vmware.com>
17183
17184	* server.c (handle_query): Discard unused value.
17185
17186	* hostio.c (require_data): Free malloc memory before returning
17187	error.
17188
171892011-02-26  Michael Snyder  <msnyder@vmware.com>
17190
17191	* linux-low.c (list_threads): Call closedir for dirent.
17192
171932011-02-27  Michael Snyder  <msnyder@vmware.com>
17194
17195	* i386-low.c (i386-length_and_rw_bits): Comment the fact that
17196	a case statement falls through.
17197
17198	* linux-low.c (linux_xfer_siginfo): Fix fencepost error.
17199
17200	* linux-amd64-ipa.c (gdb_agent_get_raw_reg): Fix fencepost error
17201	in comparison.
17202
172032011-02-26  Michael Snyder  <msnyder@vmware.com>
17204
17205	* utils.c (decimal2str): Eliminate dead code and dead param.
17206	(pulongest): Drop dead param from call to decimal2str.
17207	(plongest): Ditto.
17208
172092011-02-24  Joel Brobecker  <brobecker@adacore.com>
17210
17211	Revert the following patch (not approved yet):
17212	2011-02-21  Hui Zhu  <teawater@gmail.com>
17213	* tracepoint.c (tp_printf): New function.
17214	(eval_agent_expr): Handle gdb_agent_op_printf.
17215
172162011-02-21  Hui Zhu  <teawater@gmail.com>
17217
17218	* tracepoint.c (tp_printf): New function.
17219	(eval_agent_expr): Handle gdb_agent_op_printf.
17220
172212011-02-18  Tom Tromey  <tromey@redhat.com>
17222
17223	* Makefile.in (tracepoint-ipa.o): Depend on ax.def.
17224	(tracepoint.o): Likewise.
17225	* tracepoint.c (enum gdb_agent_op): Use ax.def.
17226	(gdb_agent_op_names): Likewise.
17227
172282011-02-18  Tom Tromey  <tromey@redhat.com>
17229
17230	* tracepoint.c (enum gdb_agent_op) <gdb_agent_op_pick,
17231	gdb_agent_op_rot>: New constants.
17232	(gdb_agent_op_names): Add pick and roll.
17233	(eval_agent_expr) <gdb_agent_op_pick, gdb_agent_op_rot>: New
17234	cases.
17235
172362011-02-15  Jan Kratochvil  <jan.kratochvil@redhat.com>
17237
17238	* aclocal.m4: Regenerated with aclocal-1.11.1.
17239
172402011-02-14  Pedro Alves  <pedro@codesourcery.com>
17241
17242	* server.c (handle_qxfer_traceframe_info): New.
17243	(qxfer_packets): Register "traceframe-info".
17244	(handle_query): Report support for qXfer:traceframe-info:read+.
17245	* tracepoint.c (match_blocktype): New.
17246	(traceframe_find_block_type): Rename to ...
17247	(traceframe_walk_blocks): ... this.  Add callback filter argument,
17248	and use it.
17249	(traceframe_find_block_type): New, reimplemented on top of
17250	traceframe_walk_blocks.
17251	(build_traceframe_info_xml): New.
17252	(traceframe_read_info): New.
17253	* server.h (traceframe_read_info): Declare.
17254
172552011-02-11  Yao Qi  <yao@codesourcery.com>
17256
17257	* configure.ac: Call AC_PROG_RANLIB.
17258	* Makefile.in: Remove signals.o from OBS.  Link libcommon.a.
17259	* configure: Regenerate.
17260
172612011-02-07  Pedro Alves  <pedro@codesourcery.com>
17262
17263	* server.c (gdb_read_memory): Change return semantics to allow
17264	partial transfers.
17265	(handle_search_memory_1): Adjust.
17266	(process_serial_event) <'m' packet>: Handle partial transfers.
17267	* tracepoint.c (traceframe_read_mem): Handle partial transfers.
17268
172692011-01-28  Pedro Alves  <pedro@codesourcery.com>
17270
17271	* regcache.c (init_register_cache): Initialize
17272	regcache->register_status.
17273	(free_register_cache): Release regcache->register_status.
17274	(regcache_cpy): Copy register_status.
17275	(registers_to_string): Print 'x's for unavailable registers.
17276	(supply_register): Mark the register's status valid or
17277	unavailable, depending on whether a buffer was passed in or not.
17278	(supply_register_zeroed): New.
17279	(supply_regblock): Mark the registers' status valid or
17280	unavailable, depending on whether a buffer was passed in or not.
17281	* regcache.h (REG_UNAVAILABLE, REG_VALID): New defines.
17282	(struct regcache): New `register_status' field.
17283	(supply_register_zeroed): Declare.
17284	* i387-fp.c (i387_xsave_to_cache): Zero out registers using
17285	supply_register_zeroed, rather than passing a NULL buffer to
17286	supply_register.
17287	* tracepoint.c (fetch_traceframe_registers): Update comment.
17288
172892011-01-28  Pedro Alves  <pedro@codesourcery.com>
17290
17291	* i387-fp.c (i387_xsave_to_cache): Make passing NULL as register
17292	buffer explicit.
17293
172942011-01-25  Pedro Alves  <pedro@codesourcery.com>
17295
17296	* server.h (decode_xfer_write): Change prototype.
17297	* remote-utils.c (decode_xfer_write): Remove `annex' parameter,
17298	and don't extract the annex here.
17299	* server.c (decode_xfer_read): Remove `annex' parameter,
17300	and don't extract the annex here.
17301	(decode_xfer): New.
17302	(struct qxfer): New.
17303	(handle_qxfer_auxv, handle_qxfer_features, handle_qxfer_libraries)
17304	(handle_qxfer_osdata, handle_qxfer_siginfo, handle_qxfer_spu)
17305	(handle_qxfer_statictrace): New functions, abstracted out from
17306	handle_query, and made to use the struct qxfer interface.
17307	(handle_threads_qxfer_proper): Rename to ...
17308	(handle_qxfer_threads_proper): ... this.
17309	(handle_threads_qxfer): Rename to ...
17310	(handle_qxfer_threads): ... this.  Adjust.
17311	(qxfer_packets): New array.
17312	(handle_qxfer): New function.
17313	(handle_query): Use handle_qxfer.
17314
173152011-01-05  Michael Snyder  <msnyder@msnyder-server.eng.vmware.com>
17316
17317	* gdbreplay.c: Shorten lines of >= 80 columns.
17318	* linux-low.c: Ditto.
17319	* linux-ppc-low.c: Ditto.
17320	* linux-s390-low.c: Ditto.
17321	* linux-sparc-low.c: Ditto.
17322	* linux-x86-low.c: Ditto.
17323	* linux-xtensa-low.c: Ditto.
17324	* mem-break.c: Ditto.
17325	* nto-low.c: Ditto.
17326	* regcache.h: Ditto.
17327	* remote-utils.c: Ditto.
17328	* server.c: Ditto.
17329	* server.h: Ditto.
17330	* thread-db.c: Ditto.
17331	* tracepoint.c: Ditto.
17332	* utils.c: Ditto.
17333	* win32-low.h: Ditto.
17334
173352011-01-05  Joel Brobecker  <brobecker@adacore.com>
17336
17337	* gdbserver/configure.ac, gdbserver/gdbserver.1: Copyright year
17338	update.
17339
173402011-01-01  Joel Brobecker  <brobecker@adacore.com>
17341
17342	* server.c (gdbserver_version): Update copyright year in version
17343	output.
17344	* gdbreplay.c (gdbreplay_version): Ditto.
17345
173462010-12-29  Jie Zhang  <jie.zhang@analog.com>
17347
17348	* configure.srv (bfin-*-*linux*): Handle Blackfin/Linux targets.
17349	* linux-bfin-low.c: New file.
17350	* linux-low.c: Define PT_TEXT_ADDR, PT_TEXT_END_ADDR, and
17351	PT_DATA_ADDR for BFIN targets.
17352	* Makefile.in (SFILES): Add linux-bfin-low.c.
17353	(clean): Remove reg-bfin.c.
17354	(linux-bfin-low.o, reg-bfin.o, reg-bfin.c): New targets.
17355	* README: Mention supported Blackfin targets.
17356
173572010-12-23  Mike Frysinger  <vapier@gentoo.org>
17358
17359	* .gitignore: New file.
17360
173612010-11-16  Mike Frysinger  <vapier@gentoo.org>
17362
17363	* linux-low.c (linux_tracefork_child): Add char* cast to arg.
17364
173652010-10-22  Jie Zhang  <jie@codesourcery.com>
17366
17367	* Makefile.in: Add FLAGS_TO_PASS variable.
17368	(install): Remove dependency of install-only and recursively
17369	invoke make for install-only.
17370
173712010-10-04  Doug Evans  <dje@google.com>
17372
17373	* Makefile.in (uninstall): Use $(DESTDIR).
17374
173752010-09-24  Pedro Alves  <pedro@codesourcery.com>
17376
17377	PR gdb/11842
17378
17379	* linux-x86-low.c (compat_siginfo_from_siginfo)
17380	(siginfo_from_compat_siginfo): Also copy si_pid and si_uid when
17381	si_code is < 0.  Check for si_code == SI_TIMER before checking for
17382	si_code < 0.
17383
173842010-09-13  Joel Brobecker  <brobecker@adacore.com>
17385
17386	* lynx-i386-low.c: New file.
17387	* configure.srv: Add handling of i[34567]86-*-lynxos* targets.
17388
173892010-09-13  Joel Brobecker  <brobecker@adacore.com>
17390
17391	* lynx-low.c (ptrace_request_to_str): Remove handling for
17392	request values that have been removed in LynxOS 5.x.
17393
173942010-09-13  Joel Brobecker  <brobecker@adacore.com>
17395
17396	* lynx-low.c, lynx-ppc-loc.c: Include <sys/ptrace.h> instead of
17397	<ptrace.h>
17398
173992010-09-09  Nathan Sidwell  <nathan@codesourcery.com>
17400
17401	* configure.ac: Add --enable-inprocess-agent option.
17402	* configure: Rebuilt.
17403
174042010-09-06  Yao Qi  <yao@codesourcery.com>
17405
17406	* linux-low.c (linux_kill): Remove unused variable.
17407	(linux_stabilize_threads): Likewise.
17408	* server.c (start_inferior): Likewise.
17409	(queue_stop_reply_callback): Likewise.
17410	* tracepoint.c (do_action_at_tracepoint): Likewise.
17411
174122010-09-06  Yao Qi  <yao@codesourcery.com>
17413
17414	* linux-low.c (maybe_move_out_of_jump_pad): Restore current_inferior
17415	on return.
17416
174172010-09-06  Jan Kratochvil  <jan.kratochvil@redhat.com>
17418
17419	* target.c (mywait) <TARGET_WAITKIND_EXITED>: Fix to use INTEGER.
17420
174212010-09-06  Pedro Alves  <pedro@codesourcery.com>
17422
17423	* Makefile.in (install-only): Replace $IPA_DEPFILES with
17424	"$(IPA_DEPFILES)".
17425
174262010-09-01  Joel Brobecker  <brobecker@adacore.com>
17427
17428	* gdbserver/lynx-low.c, gdbserver/lynx-low.h,
17429	gdbserver/lynx-ppc-low.c: New files.
17430	* Makefile.in (lynx_low_h): New variable.
17431	(lynx-low.o, lynx-ppc-low.o): New rules.
17432	* configure.ac: On LynxOS, link with -lnetinet.
17433	* configure.srv: Add handling of powerpc-*-lynxos* targets.
17434	* configure: regenerate.
17435
174362010-09-01  Joel Brobecker  <brobecker@adacore.com>
17437
17438	* Makefile.in (vasprintf.o, vsnprintf.o): New rules.
17439	* configure.ac: Add check for vasprintf and vsnprintf.
17440	* configure, config.in: Regenerate.
17441	* server.h (vasprintf, vsnprintf): Add conditional declarations.
17442
174432010-09-01  Joel Brobecker  <brobecker@adacore.com>
17444
17445	* gdbreplay.c: Move include of alloca.h up, next to include of
17446	malloc.h.
17447	* server.h: Add include of malloc.h.
17448	* mem-break.c: Remove include of malloc.h.
17449	* server.c, tracepoint.c, utils.c, win32-low.c: Likewise.
17450
174512010-09-01  Joel Brobecker  <brobecker@adacore.com>
17452
17453	* Makefile.in (memmem.o): Build with -Wno-error.
17454
174552010-09-01  Joel Brobecker  <brobecker@adacore.com>
17456
17457	* utils.c (xsnprintf): Make non-static.
17458	* server.h: Add xsnprintf declaration.
17459	* linux-low.c, nto-low.c, target.c, thread-db.c, tracepoint.c:
17460	replace calls to snprintf by calls to xsnprintf throughout.
17461
174622010-09-01  Joel Brobecker  <brobecker@adacore.com>
17463
17464	* configure.ac: Add configure check for alloca.
17465	* configure, config.in: Regenerate.
17466	* server.h: Include alloca.h if it exists.
17467	* gdbreplay.c: Include alloca.h if it exists.
17468
174692010-08-28  Pedro Alves  <pedro@codesourcery.com>
17470
17471	* linux-low.c (__SIGRTMIN): Define if not already defined.
17472	(linux_create_inferior): Check for __ANDROID__ rather than
17473	__SIGRTMIN.
17474	(enqueue_one_deferred_signal): Don't requeue non-RT signals that
17475	are already deferred.
17476	(linux_wait_1): Check for __ANDROID__ rather than __SIGRTMIN.
17477	(linux_resume_one_thread): Don't queue a SIGSTOP if the lwp is
17478	stopped and already has a pending signal to report.
17479	(proceed_one_lwp): : Don't queue a SIGSTOP if the lwp already has
17480	a pending signal to report or is moving out of a jump pad.
17481	(linux_init_signals): Check for __ANDROID__ rather than
17482	__SIGRTMIN.
17483
174842010-08-28  Pedro Alves  <pedro@codesourcery.com>
17485
17486	* linux-low.c (linux_stabilize_threads): Wrap debug output in a
17487	debug_threads check.  Avoid a linear search when not doing debug
17488	output.
17489
174902010-08-27  Pedro Alves  <pedro@codesourcery.com>
17491
17492	* event-loop.c (event_handle_func): Adjust to use gdb_fildes_t.
17493	(struct gdb_event) <fd>: Change type to gdb_fildes_t.
17494	(struct file_handler) <fd>: Change type to gdb_fildes_t.
17495	(process_event): Change local fd's type to gdb_fildes_t.
17496	(create_file_handler): Adjust prototype.
17497	(delete_file_handler): Adjust prototype.
17498	(handle_file_event): Adjust prototype.  Use pfildes.
17499	(create_file_event): Adjsut prototype.
17500	* remote-utils.c (remote_desc, listen_desc): Change type to
17501	gdb_fildes_t.
17502	* server.h: New gdb_fildes_t typedef.
17503	[USE_WIN32API]: Include winsock2.h.
17504	(delete_file_handler, add_file_handler): Adjust prototypes.
17505	(pfildes): Declare.
17506	* utils.c (pfildes): New.
17507
175082010-08-27  Pedro Alves  <pedro@codesourcery.com>
17509
17510	* configure.ac (build_warnings): Add -Wno-char-subscripts.
17511	* configure: Regenerate.
17512
175132010-08-27  Pedro Alves  <pedro@codesourcery.com>
17514
17515	* linux-low.c (linux_unprepare_to_access_memory): Rename to ...
17516	(linux_done_accessing_memory): ... this.
17517	(linux_target_ops): Adjust.
17518	* linux-x86-low.c (x86_insert_point, x86_remove_point): Adjust.
17519	* nto-low.c (nto_target_ops): Adjust comment.
17520	* server.c (gdb_read_memory, gdb_write_memory): Adjust.
17521	* spu-low.c (spu_target_ops): Adjust comment.
17522	* target.h (target_ops): Rename unprepare_to_access_memory field
17523	to done_accessing_memory.
17524	(unprepare_to_access_memory): Rename to ...
17525	(done_accessing_memory): ... this.
17526
175272010-08-26  Pedro Alves  <pedro@codesourcery.com>
17528
17529	* linux-low.c (linux_prepare_to_access_memory): New.
17530	(linux_unprepare_to_access_memory): New.
17531	(linux_target_ops): Install them.
17532	* server.c (read_memory): Rename to ...
17533	(gdb_read_memory): ... this.  Use
17534	prepare_to_access_memory/prepare_to_access_memory.
17535	(write_memory): Rename to ...
17536	(gdb_write_memory): ... this.  Use
17537	prepare_to_access_memory/prepare_to_access_memory.
17538	(handle_search_memory_1): Adjust.
17539	(process_serial_event): Adjust.
17540	* target.h (struct target_ops): New fields
17541	prepare_to_access_memory and unprepare_to_access_memory.
17542	(prepare_to_access_memory, unprepare_to_access_memory): New.
17543	* linux-x86-low.c (x86_insert_point, x86_remove_point): Use
17544	prepare_to_access_memory/prepare_to_access_memory.
17545	* nto-low.c (nto_target_ops): Adjust.
17546	* spu-low.c (spu_target_ops): Adjust.
17547	* win32-low.c (win32_target_ops): Adjust.
17548
175492010-08-26  Pedro Alves  <pedro@codesourcery.com>
17550
17551	* Makefile.in (WARN_CFLAGS): Get it from configure.
17552	(WERROR_CFLAGS): New.
17553	(INTERNAL_CFLAGS): Add WERROR_CFLAGS.
17554	* configure.ac: Introduce --enable-werror, which adds -Werror to
17555	the compiler command line.  Enabled by default.  Disable with
17556	--disable-werror.  Add -Wdeclaration-after-statement
17557	Wpointer-arith and -Wformat-nonliteral to warning flags.
17558	* configure: Regenerate.
17559
175602010-08-26  Pedro Alves  <pedro@codesourcery.com>
17561
17562	* mem-break.c [HAVE_MALLOC_H]: Include malloc.h.
17563
175642010-08-26  Pedro Alves  <pedro@codesourcery.com>
17565
17566	* gdbreplay.c (remote_error): New.
17567	(gdbchar): New.
17568	(expect): Use gdbchar.  Check for error reading from GDB.
17569	Clarify sync error output.
17570	(play): Check for errors writing to GDB.
17571	* linux-low.c (sigchld_handler): Really ignore `write' errors.
17572	* remote-utils.c (getpkt): Check for errors writing to the remote
17573	descriptor.
17574
175752010-08-25  Pedro Alves  <pedro@codesourcery.com>
17576
17577	* linux-low.c (linux_wait_1): Move non-debugging code out of
17578	`debug_threads' control.
17579
175802010-08-25  Pedro Alves  <pedro@codesourcery.com>
17581
17582	* linux-low.c (linux_wait_1): Don't set last_status here.
17583	* server.c (push_event, queue_stop_reply_callback): Assert we're
17584	not pushing a TARGET_WAITKIND_IGNORE event.
17585	(start_inferior, start_inferior, attach_inferior, handle_v_cont)
17586	(myresume, handle_target_event): Set the thread's last_resume_kind
17587	and last_status from the target returned status.
17588
175892010-08-25  Pedro Alves  <pedro@codesourcery.com>
17590
17591	PR threads/10729
17592
17593	* linux-x86-low.c (update_debug_registers_callback): New.
17594	(i386_dr_low_set_addr): Use it.
17595	(i386_dr_low_get_addr): New.
17596	(i386_dr_low_set_control): Use update_debug_registers_callback.
17597	(i386_dr_low_get_control): New.
17598	(i386_dr_low_get_status): Adjust.
17599	* linux-low.c (linux_stop_lwp): New.
17600	* linux-low.h (linux_stop_lwp): Declare.
17601
17602	* i386-low.c (I386_DR_GET_RW_LEN): Take the dr7 contents as
17603	argument instead of a i386_debug_reg_state.
17604	(I386_DR_WATCH_HIT): Take the dr6 contents as argument instead of
17605	a i386_debug_reg_state.
17606	(i386_insert_aligned_watchpoint): Adjust.
17607	(i386_remove_aligned_watchpoint): Adjust.
17608	(i386_low_stopped_data_address): Read the debug registers from the
17609	inferior instead of from the mirrors.
17610	* i386-low.h (struct i386_debug_reg_state): Extend comment.
17611	(i386_dr_low_get_addr): Declare.
17612	(i386_dr_low_get_control): Declare.
17613	(i386_dr_low_get_status): Change prototype.
17614
17615	* win32-i386-low.c (dr_status_mirror, dr_control_mirror): New globals.
17616	(i386_dr_low_get_addr): New.
17617	(i386_dr_low_get_control): New.
17618	(i386_dr_low_get_status): Adjust prototype.  Return
17619	dr_status_mirror.
17620	(i386_initial_stuff): Clear dr_status_mirror and
17621	dr_control_mirror.
17622	(i386_get_thread_context): Adjust.
17623	(i386_set_thread_context): Adjust.
17624	(i386_thread_added): Adjust.
17625
176262010-08-24  Pedro Alves  <pedro@codesourcery.com>
17627
17628	* linux-low.h (linux_thread_area): Delete declaration.
17629
176302010-08-11  Thomas Schwinge  <thomas@codesourcery.com>
17631
17632	* linux-low.c (linux_wait_1): Correctly return the ptid of the child
17633	after its termination.
17634
176352010-08-09  Pedro Alves  <pedro@codesourcery.com>
17636
17637	* linux-low.c (gdb_wants_lwp_stopped): Delete.
17638	(gdb_wants_all_stopped): Delete.
17639	(linux_wait_1): Don't call them.
17640	* server.c (handle_v_cont): Tag all threads as want-stopped.
17641	(gdb_wants_thread_stopped): Fix comments.  Tag the thread that
17642	stopped as "client-wants-stopped".
17643
176442010-07-31  Pedro Alves  <pedro@codesourcery.com>
17645
17646	* Makefile.in (signals_h): New.
17647	(server_h): Depend on it.
17648	(server.o): Don't depend on $(signals_def).
17649	(signals.o): Depend on $(signals_def).
17650
176512010-07-31  Jan Kratochvil  <jan.kratochvil@redhat.com>
17652
17653	* Makefile.in (signals_def): New.
17654	(server_h): Append include/gdb/signals.h and signals_def.
17655	(server.o): Append signals_def.
17656
176572010-07-25  Jan Kratochvil  <jan.kratochvil@redhat.com>
17658
17659	* server.c (handle_target_event): Use target_signal_to_host for
17660	resume_info.sig initialization.
17661	* target.h (struct thread_resume) <sig>: New comment.
17662
176632010-07-20  Ozkan Sezer  <sezeroz@gmail.com>
17664
17665	* server.c (handle_query): strcpy() the returned string from paddress()
17666	instead of sprintf().
17667	* utils.c (paddress): Return phex_nz().
17668
176692010-07-07  Joel Brobecker  <brobecker@adacore.com>
17670
17671	* server.c (handle_v_cont): Call mourn_inferior if process
17672	just exited.
17673	(myresume): Likewise.
17674
176752010-07-01  Pedro Alves  <pedro@codesourcery.com>
17676
17677	Static tracepoints, and integration with UST.
17678
17679	* configure.ac: Handle --with-ust.  substitute ustlibs and ustinc.
17680	* mem-break.c (uninsert_all_breakpoints)
17681	(reinsert_all_breakpoints): New.
17682	* mem-break.h (reinsert_all_breakpoints, uninsert_all_breakpoints):
17683	* tracepoint.c (ust_loaded, helper_thread_id, cmd_buf): New.
17684	(gdb_agent_ust_loaded, helper_thread_id)
17685	(gdb_agent_helper_thread_id): New macros.
17686	(struct ipa_sym_addresses): Add addr_ust_loaded,
17687	addr_helper_thread_id, addr_cmd_buf.
17688	(symbol_list): Add ust_loaded, helper_thread_id, cmd_buf.
17689	(in_process_agent_loaded_ust): New.
17690	(write_e_ust_not_loaded): New.
17691	(maybe_write_ipa_ust_not_loaded): New.
17692	(struct collect_static_trace_data_action): New.
17693	(enum tracepoint_type) <static_tracepoint>: New.
17694	(struct tracepoint) <handle>: Mention static tracepoints.
17695	(struct static_tracepoint_ctx): New.
17696	(CMD_BUF_SIZE): New.
17697	(add_tracepoint_action): Handle static tracepoint actions.
17698	(unprobe_marker_at): New.
17699	(clear_installed_tracepoints): Handle static tracepoints.
17700	(cmd_qtdp): Handle static tracepoints.
17701	(probe_marker_at): New.
17702	(cmd_qtstart): Handle static tracepoints.
17703	(response_tracepoint): Handle static tracepoints.
17704	(cmd_qtfstm, cmd_qtsstm, cmd_qtstmat): New.
17705	(handle_tracepoint_query): Handle qTfSTM, qTsSTM and qTSTMat.
17706	(get_context_regcache): Handle static tracepoints.
17707	(do_action_at_tracepoint): Handle static tracepoint actions.
17708	(traceframe_find_block_type): Handle static trace data blocks.
17709	(traceframe_read_sdata): New.
17710	(download_tracepoints): Download static tracepoint actions.
17711	[HAVE_UST] Include ust/ust.h, dlfcn.h, sys/socket.h, and sys/un.h.
17712	(GDB_PROBE_NAME): New.
17713	(ust_ops): New.
17714	(GET_UST_SYM): New.
17715	(USTF): New.
17716	(dlsym_ust): New.
17717	(ust_marker_to_static_tracepoint): New.
17718	(gdb_probe): New.
17719	(collect_ust_data_at_tracepoint): New.
17720	(gdb_ust_probe): New.
17721	(UNIX_PATH_MAX, SOCK_DIR): New.
17722	(gdb_ust_connect_sync_socket): New.
17723	(resume_thread, stop_thread): New.
17724	(run_inferior_command): New.
17725	(init_named_socket): New.
17726	(gdb_ust_socket_init): New.
17727	(cstr_to_hexstr): New.
17728	(next_st): New.
17729	(first_marker, next_marker): New.
17730	(response_ust_marker): New.
17731	(cmd_qtfstm, cmd_qtsstm): New.
17732	(unprobe_marker_at, probe_marker_at): New.
17733	(cmd_qtstmat, gdb_ust_thread): New.
17734	(gdb_ust_init): New.
17735	(initialize_tracepoint_ftlib): Call gdb_ust_init.
17736	* linux-amd64-ipa.c [HAVE_UST]: Include ust/processor.h
17737	(ST_REGENTRY): New.
17738	(x86_64_st_collect_regmap): New.
17739	(X86_64_NUM_ST_COLLECT_GREGS): New.
17740	(AMD64_RIP_REGNUM): New.
17741	(supply_static_tracepoint_registers): New.
17742	* linux-i386-ipa.c [HAVE_UST]: Include ust/processor.h
17743	(ST_REGENTRY): New.
17744	(i386_st_collect_regmap): New.
17745	(i386_NUM_ST_COLLECT_GREGS): New.
17746	(supply_static_tracepoint_registers): New.
17747	* server.c (handle_query): Handle qXfer:statictrace:read.
17748	<qSupported>: Report support for StaticTracepoints, and
17749	qXfer:statictrace:read features.
17750	* server.h (traceframe_read_sdata)
17751	(supply_static_tracepoint_registers): Declare.
17752	* remote-utils.c (convert_int_to_ascii, hexchars, ishex, tohex)
17753	(unpack_varlen_hex): Include in IPA build.
17754	* Makefile.in (ustlibs, ustinc): New.
17755	(IPA_OBJS): Add remote-utils-ipa.o.
17756	($(IPA_LIB)): Link -ldl and -lpthread.
17757	(UST_CFLAGS): New.
17758	(IPAGENT_CFLAGS): Add UST_CFLAGS.
17759	* config.in, configure: Regenerate.
17760
177612010-06-20  Ian Lance Taylor  <iant@google.com>
17762	    Pedro Alves  <pedro@codesourcery.com>
17763
17764	* linux-x86-low.c (always_true): Delete.
17765	(EMIT_ASM, EMIT_ASM32): Use an uncondition asm jmp instead of
17766	trying to fool the compiler with always_true.
17767
177682010-06-20  Pedro Alves  <pedro@codesourcery.com>
17769
17770	* tracepoint.c (condition_true_at_tracepoint): Don't run compiled
17771	conditions in gdbserver.
17772
177732010-06-19  Ulrich Weigand  <uweigand@de.ibm.com>
17774
17775	* spu-low.c (spu_read_memory): Wrap around local store limit.
17776	(spu_write_memory): Likewise.
17777
177782010-06-15  Pedro Alves  <pedro@codesourcery.com>
17779
17780	* linux-x86-low.c (amd64_emit_const, amd64_emit_void_call_2)
17781	(i386_emit_const, i386_emit_void_call_2): Replace int64_t uses with
17782	LONGEST uses.
17783	* server.h (struct emit_ops): Replace int64_t uses with LONGEST
17784	uses.
17785	* tracepoint.c (emit_const, emit_void_call_2): Replace int64_t
17786	uses with LONGEST uses.
17787
177882010-06-14  Stan Shebs  <stan@codesourcery.com>
17789	    Pedro Alves  <pedro@codesourcery.com>
17790
17791	Bytecode compiler.
17792
17793	* linux-x86-low.c: Include limits.h.
17794	(add_insns): New.
17795	(always_true): New.
17796	(EMIT_ASM): New.
17797	(EMIT_ASM32): New.
17798	(amd64_emit_prologue, amd64_emit_epilogue, amd64_emit_add)
17799	(amd64_emit_sub, amd64_emit_mul, amd64_emit_lsh)
17800	(amd64_emit_rsh_signed, amd64_emit_rsh_unsigned, amd64_emit_ext,
17801	(amd64_emit_log_not, amd64_emit_bit_and, amd64_emit_bit_or)
17802	(amd64_emit_bit_xor, amd64_emit_bit_not, amd64_emit_equal,
17803	(amd64_emit_less_signed, amd64_emit_less_unsigned, amd64_emit_ref,
17804	(amd64_emit_if_goto, amd64_emit_goto, amd64_write_goto_address)
17805	(amd64_emit_const, amd64_emit_call, amd64_emit_reg)
17806	(amd64_emit_pop, amd64_emit_stack_flush, amd64_emit_zero_ext)
17807	(amd64_emit_swap, amd64_emit_stack_adjust, amd64_emit_int_call_1)
17808	(amd64_emit_void_call_2): New.
17809	(amd64_emit_ops): New.
17810	(i386_emit_prologue, i386_emit_epilogue, i386_emit_add)
17811	(i386_emit_sub,i386_emit_mul, i386_emit_lsh, i386_emit_rsh_signed)
17812	(i386_emit_rsh_unsigned, i386_emit_ext, i386_emit_log_not)
17813	(i386_emit_bit_and, i386_emit_bit_or, i386_emit_bit_xor)
17814	(i386_emit_bit_not, i386_emit_equal, i386_emit_less_signed)
17815	(i386_emit_less_unsigned, i386_emit_ref, i386_emit_if_goto)
17816	(i386_emit_goto, i386_write_goto_address, i386_emit_const)
17817	(i386_emit_call, i386_emit_reg, i386_emit_pop)
17818	(i386_emit_stack_flush, i386_emit_zero_ext, i386_emit_swap)
17819	(i386_emit_stack_adjust, i386_emit_int_call_1)
17820	(i386_emit_void_call_2): New.
17821	(i386_emit_ops): New.
17822	(x86_emit_ops): New.
17823	(the_low_target): Install x86_emit_ops.
17824	* server.h (struct emit_ops): New.
17825	(get_raw_reg_func_addr): Declare.
17826	(current_insn_ptr, emit_error): Declare.
17827	* tracepoint.c (get_raw_reg, get_trace_state_variable_value)
17828	(set_trace_state_variable_value): New defines.
17829	(struct ipa_sym_addresses): New fields addr_get_raw_reg,
17830	addr_get_trace_state_variable_value and
17831	addr_set_trace_state_variable_value.
17832	(symbol_list): New fields for get_raw_reg,
17833	get_trace_state_variable_value and set_trace_state_variable_value.
17834	(condfn): New typedef.
17835	(struct tracepoint): New field `compiled_cond'.
17836	(do_action_at_tracepoint): Clear compiled_cond.
17837	(get_trace_state_variable_value, set_trace_state_variable_value):
17838	Export in the IPA.
17839	(condition_true_at_tracepoint): If there's a compiled condition,
17840	run that.
17841	(current_insn_ptr, emit_error): New globals.
17842	(struct bytecode_address): New.
17843	(get_raw_reg_func_addr): New.
17844	(emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul)
17845	(emit_lsh, emit_rsh_signed, emit_rsh_unsigned, emit_ext)
17846	(emit_log_not, emit_bit_and, emit_bit_or, emit_bit_xor)
17847	(emit_bit_not, emit_equal, emit_less_signed, emit_less_unsigned)
17848	(emit_ref, emit_if_goto, emit_goto, write_goto_address, emit_const)
17849	(emit_reg, emit_pop, emit_stack_flush, emit_zero_ext, emit_swap)
17850	(emit_stack_adjust, emit_int_call_1, emit_void_call_2): New.
17851	(compile_tracepoint_condition, compile_bytecodes): New.
17852	* target.h (emit_ops): Forward declare.
17853	(struct target_ops): New field emit_ops.
17854	(target_emit_ops): New.
17855	* linux-amd64-ipa.c (gdb_agent_get_raw_reg): New.
17856	* linux-i386-ipa.c (gdb_agent_get_raw_reg): New.
17857	* linux-low.c (linux_emit_ops): New.
17858	(linux_target_ops): Install it.
17859	* linux-low.h (struct linux_target_ops): New field emit_ops.
17860
178612010-06-14  Ulrich Weigand  <uweigand@de.ibm.com>
17862
17863	* linux-ppc-low.c (ppc_arch_setup): Use private regcache to test MSR.
17864	* linux-s390-low.c (ppc_arch_setup): Use private regcache to test PSW.
17865
178662010-06-01  Pedro Alves  <pedro@codesourcery.com>
17867	    Stan Shebs  <stan@codesourcery.com>
17868
17869	* Makefile.in (IPA_DEPFILES, extra_libraries): New.
17870	(all): Depend on $(extra_libraries).
17871	(install-only): Install the IPA.
17872	(IPA_OBJS, IPA_LIB): New.
17873	(clean): Remove the IPA lib.
17874	(IPAGENT_CFLAGS): New.
17875	(tracepoint-ipa.o, utils-ipa.o, remote-utils-ipa.o)
17876	(regcache-ipa.o, i386-linux-ipa.o, linux-i386-ipa.o)
17877	(linux-amd64-ipa.o, amd64-linux-ipa.o): New rules.
17878	* linux-amd64-ipa.c, linux-i386-ipa.c: New files.
17879	* configure.ac: Check for atomic builtins support in the compiler.
17880	(IPA_DEPFILES, extra_libraries): Define.
17881	* configure.srv (ipa_obj): Add description.
17882	(ipa_i386_linux_regobj, ipa_amd64_linux_regobj): Define.
17883	(i[34567]86-*-linux*): Set ipa_obj.
17884	(x86_64-*-linux*): Set ipa_obj.
17885	* linux-low.c (stabilizing_threads): New.
17886	(supports_fast_tracepoints): New.
17887	(linux_detach): Stabilize threads before detaching.
17888	(handle_tracepoints): Handle internal tracing breakpoints.  Assert
17889	the lwp is either not stabilizing, or is moving out of a jump pad.
17890	(linux_fast_tracepoint_collecting): New.
17891	(maybe_move_out_of_jump_pad): New.
17892	(enqueue_one_deferred_signal): New.
17893	(dequeue_one_deferred_signal): New.
17894	(linux_wait_for_event_1): If moving out of a jump pad, defer
17895	pending signals to later.
17896	(linux_stabilize_threads): New.
17897	(linux_wait_1): Check if threads need moving out of jump pads, and
17898	do it if so.
17899	(stuck_in_jump_pad_callback): New.
17900	(move_out_of_jump_pad_callback): New.
17901	(lwp_running): New.
17902	(linux_resume_one_lwp): Handle moving out of jump pads.
17903	(linux_set_resume_request): Dequeue deferred signals.
17904	(need_step_over_p): Also step over fast tracepoint jumps.
17905	(start_step_over): Also uninsert fast tracepoint jumps.
17906	(finish_step_over): Also reinsert fast tracepoint jumps.
17907	(linux_install_fast_tracepoint_jump): New.
17908	(linux_target_ops): Install linux_stabilize_threads and
17909	linux_install_fast_tracepoint_jump_pad.
17910	* linux-low.h (linux_target_ops) <get_thread_area,
17911	install_fast_tracepoint_jump_pad>: New fields.
17912	(struct lwp_info) <collecting_fast_tracepoint,
17913	pending_signals_to_report, exit_jump_pad_bkpt>: New fields.
17914	(linux_get_thread_area): Declare.
17915	* linux-x86-low.c (jump_insn): New.
17916	(x86_get_thread_area): New.
17917	(append_insns): New.
17918	(push_opcode): New.
17919	(amd64_install_fast_tracepoint_jump_pad): New.
17920	(i386_install_fast_tracepoint_jump_pad): New.
17921	(x86_install_fast_tracepoint_jump_pad): New.
17922	(the_low_target): Install x86_get_thread_area and
17923	x86_install_fast_tracepoint_jump_pad.
17924	* mem-break.c (set_raw_breakpoint_at): Use read_inferior_memory.
17925	(struct fast_tracepoint_jump): New.
17926	(fast_tracepoint_jump_insn): New.
17927	(fast_tracepoint_jump_shadow): New.
17928	(find_fast_tracepoint_jump_at): New.
17929	(fast_tracepoint_jump_here): New.
17930	(delete_fast_tracepoint_jump): New.
17931	(set_fast_tracepoint_jump): New.
17932	(uninsert_fast_tracepoint_jumps_at): New.
17933	(reinsert_fast_tracepoint_jumps_at): New.
17934	(set_breakpoint_at): Use write_inferior_memory.
17935	(uninsert_raw_breakpoint): Use write_inferior_memory.
17936	(check_mem_read): Mask out fast tracepoint jumps.
17937	(check_mem_write): Mask out fast tracepoint jumps.
17938	* mem-break.h (struct fast_tracepoint_jump): Forward declare.
17939	(set_fast_tracepoint_jump): Declare.
17940	(delete_fast_tracepoint_jump)
17941	(fast_tracepoint_jump_here, uninsert_fast_tracepoint_jumps_at)
17942	(reinsert_fast_tracepoint_jumps_at): Declare.
17943	* regcache.c: Don't compile many functions when building the
17944	in-process agent library.
17945	(init_register_cache) [IN_PROCESS_AGENT]: Don't allow allocating
17946	the register buffer in the heap.
17947	(free_register_cache): If the register buffer isn't owned by the
17948	regcache, don't free it.
17949	(set_register_cache) [IN_PROCESS_AGENT]: Don't re-alocate
17950	pre-existing register caches.
17951	* remote-utils.c (convert_int_to_ascii): Constify `from' parameter
17952	type.
17953	(convert_ascii_to_int): : Constify `from' parameter type.
17954	(decode_M_packet, decode_X_packet): Replace the `to' parameter by
17955	a `to_p' pointer to pointer parameter.  If TO_P is NULL, malloc
17956	the needed buffer in-place.
17957	(relocate_instruction): New.
17958	* server.c (handle_query) <qSymbols>: If the target supports
17959	tracepoints, give it a chance of looking up symbols.  Report
17960	support for fast tracepoints.
17961	(handle_status): Stabilize threads.
17962	(process_serial_event): Adjust.
17963	* server.h (struct fast_tracepoint_jump): Forward declare.
17964	(struct process_info) <fast_tracepoint_jumps>: New field.
17965	(convert_ascii_to_int, convert_int_to_ascii): Adjust.
17966	(decode_X_packet, decode_M_packet): Adjust.
17967	(relocate_instruction): Declare.
17968	(in_process_agent_loaded): Declare.
17969	(tracepoint_look_up_symbols): Declare.
17970	(struct fast_tpoint_collect_status): Declare.
17971	(fast_tracepoint_collecting): Declare.
17972	(force_unlock_trace_buffer): Declare.
17973	(handle_tracepoint_bkpts): Declare.
17974	(initialize_low_tracepoint)
17975	(supply_fast_tracepoint_registers) [IN_PROCESS_AGENT]: Declare.
17976	* target.h (struct target_ops) <stabilize_threads,
17977	install_fast_tracepoint_jump_pad>: New fields.
17978	(stabilize_threads, install_fast_tracepoint_jump_pad): New.
17979	* tracepoint.c [HAVE_MALLOC_H]: Include malloc.h.
17980	[HAVE_STDINT_H]: Include stdint.h.
17981	(trace_debug_1): Rename to ...
17982	(trace_vdebug): ... this.
17983	(trace_debug): Rename to ...
17984	(trace_debug_1): ... this.  Add `level' parameter.
17985	(trace_debug): New.
17986	(ATTR_USED, ATTR_NOINLINE): New.
17987	(IP_AGENT_EXPORT): New.
17988	(gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
17989	(collecting, gdb_collect, stop_tracing, flush_trace_buffer)
17990	(about_to_request_buffer_space, trace_buffer_is_full)
17991	(stopping_tracepoint, expr_eval_result, error_tracepoint)
17992	(tracepoints, tracing, trace_buffer_ctrl, trace_buffer_ctrl_curr)
17993	(trace_buffer_lo, trace_buffer_hi, traceframe_read_count)
17994	(traceframe_write_count, traceframes_created)
17995	(trace_state_variables)
17996	New renaming defines.
17997	(struct ipa_sym_addresses): New.
17998	(STRINGIZE_1, STRINGIZE, IPA_SYM): New.
17999	(symbol_list): New.
18000	(ipa_sym_addrs): New.
18001	(all_tracepoint_symbols_looked_up): New.
18002	(in_process_agent_loaded): New.
18003	(write_e_ipa_not_loaded): New.
18004	(maybe_write_ipa_not_loaded): New.
18005	(tracepoint_look_up_symbols): New.
18006	(debug_threads) [IN_PROCESS_AGENT]: New.
18007	(read_inferior_memory) [IN_PROCESS_AGENT]: New.
18008	(UNKNOWN_SIDE_EFFECTS): New.
18009	(stop_tracing): New.
18010	(flush_trace_buffer): New.
18011	(stop_tracing_bkpt): New.
18012	(flush_trace_buffer_bkpt): New.
18013	(read_inferior_integer): New.
18014	(read_inferior_uinteger): New.
18015	(read_inferior_data_pointer): New.
18016	(write_inferior_data_pointer): New.
18017	(write_inferior_integer): New.
18018	(write_inferior_uinteger): New.
18019	(struct collect_static_trace_data_action): Delete.
18020	(enum tracepoint_type): New.
18021	(struct tracepoint) <type>: New field `type'.
18022	<actions_str, step_actions, step_actions_str>: Only include in
18023	GDBserver.
18024	<orig_size, obj_addr_on_target, adjusted_insn_addr>
18025	<adjusted_insn_addr_end, jump_pad, jump_pad_end>: New fields.
18026	(tracepoints): Use IP_AGENT_EXPORT.
18027	(last_tracepoint): Don't include in the IPA.
18028	(stopping_tracepoint): Use IP_AGENT_EXPORT.
18029	(trace_buffer_is_full): Use IP_AGENT_EXPORT.
18030	(alloced_trace_state_variables): New.
18031	(trace_state_variables): Use IP_AGENT_EXPORT.
18032	(traceframe_t): Delete unused variable.
18033	(circular_trace_buffer): Don't include in the IPA.
18034	(trace_buffer_start): Delete.
18035	(struct trace_buffer_control): New.
18036	(trace_buffer_free): Delete.
18037	(struct ipa_trace_buffer_control): New.
18038	(GDBSERVER_FLUSH_COUNT_MASK, GDBSERVER_FLUSH_COUNT_MASK_PREV)
18039	(GDBSERVER_FLUSH_COUNT_MASK_CURR, GDBSERVER_UPDATED_FLUSH_COUNT_BIT):
18040	New.
18041	(trace_buffer_ctrl): New.
18042	(TRACE_BUFFER_CTRL_CURR): New.
18043	(trace_buffer_start, trace_buffer_free, trace_buffer_end_free):
18044	Reimplement as macros.
18045	(trace_buffer_wrap): Delete.
18046	(traceframe_write_count, traceframe_read_count)
18047	(traceframes_created, tracing): Use IP_AGENT_EXPORT.
18048	(struct tracepoint_hit_ctx) <type>: New field.
18049	(struct fast_tracepoint_ctx): New.
18050	(memory_barrier): New.
18051	(cmpxchg): New.
18052	(record_tracepoint_error): Update atomically in the IPA.
18053	(clear_inferior_trace_buffer): New.
18054	(about_to_request_buffer_space): New.
18055	(trace_buffer_alloc): Handle GDBserver and inferior simulatenous
18056	updating the same buffer.
18057	(add_tracepoint): Default the tracepoint's type to trap
18058	tracepoint, and orig_size to -1.
18059	(get_trace_state_variable) [IN_PROCESS_AGENT]: Handle allocated
18060	internal variables.
18061	(create_trace_state_variable): New parameter `gdb'.  Handle it.
18062	(clear_installed_tracepoints): Clear fast tracepoint jumps.
18063	(cmd_qtdp): Handle fast tracepoints.
18064	(cmd_qtdv): Adjust.
18065	(max_jump_pad_size): New.
18066	(gdb_jump_pad_head): New.
18067	(get_jump_space_head): New.
18068	(claim_jump_space): New.
18069	(sort_tracepoints): New.
18070	(MAX_JUMP_SIZE): New.
18071	(cmd_qtstart): Handle fast tracepoints.  Sync tracepoints with the
18072	IPA.
18073	(stop_tracing) [IN_PROCESS_AGENT]: Don't include the tdisconnected
18074	support.  Upload fast traceframes, and delete internal IPA
18075	breakpoints.
18076	(stop_tracing_handler): New.
18077	(flush_trace_buffer_handler): New.
18078	(cmd_qtstop): Upload fast tracepoints.
18079	(response_tracepoint): Handle fast tracepoints.
18080	(tracepoint_finished_step): Upload fast traceframes.  Set the
18081	tracepoint hit context's tracepoint type.
18082	(handle_tracepoint_bkpts): New.
18083	(tracepoint_was_hit): Set the tracepoint hit context's tracepoint
18084	type.  Add comment about fast tracepoints.
18085	(collect_data_at_tracepoint) [IN_PROCESS_AGENT]: Don't access the
18086	non-existing action_str field.
18087	(get_context_regcache): Handle fast tracepoints.
18088	(do_action_at_tracepoint) [!IN_PROCESS_AGENT]: Don't write the PC
18089	to the regcache.
18090	(fast_tracepoint_from_jump_pad_address): New.
18091	(fast_tracepoint_from_ipa_tpoint_address): New.
18092	(collecting_t): New.
18093	(force_unlock_trace_buffer): New.
18094	(fast_tracepoint_collecting): New.
18095	(collecting): New.
18096	(gdb_collect): New.
18097	(write_inferior_data_ptr): New.
18098	(target_tp_heap): New.
18099	(target_malloc): New.
18100	(download_agent_expr): New.
18101	(UALIGN): New.
18102	(download_tracepoints): New.
18103	(download_trace_state_variables): New.
18104	(upload_fast_traceframes): New.
18105	(IPA_FIRST_TRACEFRAME): New.
18106	(IPA_NEXT_TRACEFRAME_1): New.
18107	(IPA_NEXT_TRACEFRAME): New.
18108	[IN_PROCESS_AGENT]: Include sys/mman.h and fcntl.h.
18109	[IN_PROCESS_AGENT] (gdb_tp_heap_buffer, gdb_jump_pad_buffer)
18110	(gdb_jump_pad_buffer_end): New.
18111	[IN_PROCESS_AGENT] (initialize_tracepoint_ftlib): New.
18112	(initialize_tracepoint): Adjust.
18113	[IN_PROCESS_AGENT]: Allocate the IPA heap, and jump pad scratch
18114	buffer.  Initialize the low module.
18115	* utils.c (PREFIX, TOOLNAME): New.
18116	(malloc_failure): Use PREFIX.
18117	(error): In the IPA, an error causes an exit.
18118	(fatal, warning): Use PREFIX.
18119	(internal_error): Use TOOLNAME.
18120	(NUMCELLS): Increase to 10.
18121	* configure, config.in: Regenerate.
18122
181232010-06-01  Pedro Alves  <pedro@codesourcery.com>
18124
18125	* server.c (handle_query) <qSupported>: Do two passes over the
18126	qSupported string to avoid nesting strtok.
18127
181282010-05-28  Jan Kratochvil  <jan.kratochvil@redhat.com>
18129
18130	* Makefile.in (SFILES): Add $(srcdir)/proc-service.list.
18131	(CDEPS): New.
18132	* configure.ac (RDYNAMIC): New AC_MSG_CHECKING wrapping.  Test also
18133	-Wl,--dynamic-list.
18134	* configure: Regenerate.
18135	* proc-service.list: New.
18136
181372010-05-28  Jan Kratochvil  <jan.kratochvil@redhat.com>
18138
18139	* linux-low.c (linux_core_of_thread): Fix crash on invalid CONTENT.
18140	New comment.
18141
181422010-05-26  Ozkan Sezer  <sezeroz@gmail.com>
18143
18144	* gdbreplay.c (remote_open): Check error return from socket() call by
18145	its equality to -1 not by it being negative.
18146	* remote-utils.c (remote_open): Likewise.
18147
181482010-05-23  Pedro Alves  <pedro@codesourcery.com>
18149
18150	* config.h: Regenerate.
18151
181522010-05-19  Maxim Kuvyrkov  <maxim@codesourcery.com>
18153
18154	* linux-m68k-low.c (ps_get_thread_area): Don't define if kernel
18155	doesn't provide PTRACE_GET_THREAD_AREA.
18156
181572010-05-19  Maxim Kuvyrkov  <maxim@codesourcery.com>
18158
18159	* linux-m68k-low.c: Include <asm/ptrace.h>
18160	(ps_get_thread_area): Implement.
18161
181622010-05-03  Doug Evans  <dje@google.com>
18163
18164	* event-loop.c (struct callback_event): New struct.
18165	(callback_list): New global.
18166	(append_callback_event, delete_callback_event): New functions.
18167	(process_callback): New function.
18168	(start_event_loop): Call it.
18169	* remote-utils.c (NOT_SCHEDULED): Define.
18170	(readchar_buf, readchar_bufcnt, readchar_bufp): New static globals,
18171	moved out of readchar.
18172	(readchar): Rewrite.  Call reschedule before returning.
18173	(reset_readchar): New function.
18174	(remote_close): Call it.
18175	(process_remaining, reschedule): New functions.
18176	* server.h (callback_handler_func): New typedef.
18177	(append_callback_event, delete_callback_event): Declare.
18178
181792010-05-03  Pedro Alves  <pedro@codesourcery.com>
18180
18181	* proc-service.c (ps_pglobal_lookup): Use
18182	thread_db_look_up_one_symbol.
18183	* remote-utils.c (look_up_one_symbol): Add new `may_ask_gdb'
18184	parameter.  Use it instead of all_symbols_looked_up.
18185	* server.h (struct process_info) <all_symbols_looked_up>: Delete
18186	field.
18187	(all_symbols_looked_up): Don't declare.
18188	(look_up_one_symbol): Add new `may_ask_gdb' parameter.
18189	* thread-db.c (struct thread_db) <all_symbols_looked_up>: New
18190	field.
18191	(thread_db_look_up_symbols): Adjust call to look_up_one_symbol.
18192	Set all_symbols_looked_up here.
18193	(thread_db_look_up_one_symbol): New.
18194	(thread_db_get_tls_address): Adjust.
18195	(thread_db_load_search, try_thread_db_load_1): Always allocate the
18196	thread_db object on the heap, and tentatively set it in the
18197	process structure.
18198	(thread_db_init): Don't set all_symbols_looked_up here.
18199	* linux-low.h (thread_db_look_up_one_symbol): Declare.
18200
182012010-05-03  Pedro Alves  <pedro@codesourcery.com>
18202
18203	* linux-low.c (linux_kill, linux_detach): Adjust.
18204	(status_pending_p_callback): Remove redundant statement.  Check
18205	for !TARGET_WAITIKIND_IGNORE, instead of
18206	TARGET_WAITKIND_STOPPED.
18207	(handle_tracepoints): Make sure LWP is locked.  Adjust.
18208	(linux_wait_for_event_1): Adjust.
18209	(linux_cancel_breakpoints): New.
18210	(unsuspend_one_lwp): New.
18211	(unsuspend_all_lwps): New.
18212	(linux_wait_1): If finishing a step-over, unsuspend all lwps.
18213	(send_sigstop_callback): Change return type to int, add new
18214	`except' parameter and handle it.
18215	(suspend_and_send_sigstop_callback): New.
18216	(stop_all_lwps): Add new `suspend' and `expect' parameters, and
18217	pass them down.  If SUSPEND, also increment the lwp's suspend
18218	count.
18219	(linux_resume_one_lwp): Add notice about resuming a suspended LWP.
18220	(need_step_over_p): Don't consider suspended LWPs.
18221	(start_step_over): Adjust.
18222	(proceed_one_lwp): Change return type to int, add new `except'
18223	parameter and handle it.
18224	(unsuspend_and_proceed_one_lwp): New.
18225	(proceed_all_lwps): Use find_inferior instead of
18226	for_each_inferior.
18227	(unstop_all_lwps): Add `unsuspend' parameter.  If UNSUSPEND, them
18228	also decrement the suspend count of LWPs.  Pass `except' down,
18229	instead of hacking its suspend count.
18230	(linux_pause_all): Add `freeze' parameter.  Adjust.
18231	(linux_unpause_all): New.
18232	(linux_target_ops): Install linux_unpause_all.
18233	* server.c (handle_status): Adjust.
18234	* target.h (struct target_ops): New fields `unpause_all' and
18235	`cancel_breakpoints'.  Add new parameter to `pause_all'.
18236	(pause_all): Add new `freeze' parameter.
18237	(unpause_all): New.
18238	(cancel_breakpoints): New.
18239	* tracepoint.c (clear_installed_tracepoints): Pause threads, and
18240	cancel breakpoints.
18241	(cmd_qtstart): Pause threads.
18242	(stop_tracing): Pause threads, and cancel breakpoints.
18243	* win32-low.c (win32_target_ops): Adjust.
18244
182452010-05-03  Pedro Alves  <pedro@codesourcery.com>
18246
18247	* linux-low.c (linux_wait_for_event_1): Move passing the signal to
18248	the inferior right away from here...
18249	(linux_wait_1): ... to here, and adjust to check the thread's
18250	last_resume_kind instead of the lwp's step or stop_expected flags.
18251
182522010-05-02  Pedro Alves  <pedro@codesourcery.com>
18253
18254	* README: Use consistent `GDB' and `GDBserver' spellings.
18255
182562010-05-02  Pedro Alves  <pedro@codesourcery.com>
18257
18258	* linux-low.c (linux_kill_one_lwp): Assume the lwp is stopped.
18259	(linux_kill): Stop all lwps here.  Don't delete the main lwp here.
18260	(linux_detach_one_lwp): Assume the lwp is stopped.
18261	(any_thread_of): Delete.
18262	(linux_detach): Stop all lwps here.  Don't blindly delete all
18263	breakpoints.
18264	(delete_lwp_callback): New.
18265	(linux_mourn): Delete all lwps of the process that is gone.
18266	(linux_wait_1): Don't delete the last lwp of the process here.
18267	* mem-break.h (mark_breakpoints_out): Declare.
18268	* mem-break.c (mark_breakpoints_out): New.
18269	(free_all_breakpoints): Use it.
18270	* server.c (handle_target_event): If the process is gone, mark
18271	breakpoints out.
18272	* thread-db.c (struct thread_db) <create_bp>: New field.
18273	(thread_db_enable_reporting): Fix prototype.  Store a thread event
18274	breakpoint reference in the thread_db struct.
18275	(thread_db_load_search): Clear the thread_db object.
18276	(try_thread_db_load_1): Ditto.
18277	(switch_to_process): New.
18278	(disable_thread_event_reporting): Use it.
18279	(remove_thread_event_breakpoints): New.
18280	(thread_db_detach, thread_db_mourn): Use it.
18281
182822010-05-01  Pedro Alves  <pedro@codesourcery.com>
18283
18284	* linux-low.c (linux_enable_event_reporting): New.
18285	(linux_wait_for_event_1, handle_extended_wait): Use it.
18286
182872010-04-30  Pedro Alves  <pedro@codesourcery.com>
18288
18289	* linux-low.c (linux_kill_one_lwp, linux_kill)
18290	(linux_detach_one_lwp): Adjust to send_sigstop interface change.
18291	(send_sigstop): Take an lwp_info as parameter instead.  Queue a
18292	SIGSTOP even if the LWP is stopped.
18293	(send_sigstop_callback): New.
18294	(stop_all_lwps): Use send_sigstop_callback instead.
18295	(linux_resume_one_thread): Adjust.
18296	(proceed_one_lwp): Still proceed an LWP that the client has
18297	requested to stop, if we haven't reported it as stopped yet.  Make
18298	sure that LWPs the client want stopped, have a pending SIGSTOP.
18299
183002010-04-26  Doug Evans  <dje@google.com>
18301
18302	* server.c (handle_general_set): Make static.
18303
18304	* remote-utils.c (putpkt_binary_1): Call readchar instead of read.
18305	Print received char after testing for error/eof instead of before.
18306	(input_interrupt): Tweak comment.
18307
183082010-04-23  Doug Evans  <dje@google.com>
18309
18310	* server.c (start_inferior): Print inferior argv if --debug.
18311
183122010-04-21  Aleksandar Ristovski  <aristovski@qnx.com>
18313
18314	* Makefile.in (nto_low_h nto-low.o nto-x86-low.o): New dependency lists.
18315	* nto-x86-low.c: Include server.h
18316
183172010-04-20  Pierre Muller  <muller@ics.u-strasbg.fr>
18318
18319	* win32-i386-low.c: Use __x86_64__ macro instead of __x86_64 to
18320	be consistent with other sources of this directory.
18321	(init_registers_amd64): Correct name of source file of this function
18322	in the comment.
18323
183242010-04-19  Pierre Muller  <muller@ics.u-strasbg.fr>
18325
18326	* configure.srv (x86_64-*-mingw*): New configuration for Windows
18327	64-bit executables.
18328
183292010-04-19  Pierre Muller  <muller@ics.u-strasbg.fr>
18330
18331	* win32-i386-low.c: Add 64-bit support.
18332	(CONTEXT_EXTENDED_REGISTERS): Set macro to zero if not exisiting.
18333	(init_registers_amd64): Declare.
18334	(mappings): Add 64-bit version of array.
18335	(init_windows_x86): New function.
18336	(the_low_target): Change init_arch field to init_windows_x86.
18337
183382010-04-19  Pierre Muller  <muller@ics.u-strasbg.fr>
18339
18340	* win32-low.c: Adapt to support also 64-bit architecture.
18341	(child_xfer_memory): Use uintptr_t type for local variable `addr'.
18342	(get_image_name): Use SIZE_T type for local variable `done'.
18343	(psapi_get_dll_name): Use LPVOID type for parameter `BaseAddress'.
18344	(toolhelp_get_dll_name): Idem.
18345	(handle_load_dll): Use CORE_ADDR type for local variable `load_addr'.
18346	Use uintptr_t typecast to avoid warning.
18347	(handle_unload_dll): Use uintptr_t typecast to avoid warning.
18348	(handle_exception): Use phex_nz to avoid warning.
18349	(win32_wait): Remove unused local variable `process'.
18350
183512010-04-19  Pierre Muller  <muller@ics.u-strasbg.fr>
18352
18353	* configure.srv (srv_amd64_regobj): Replace `x86-64-avx.o' by
18354	`amd64-avx.o'.
18355
183562010-04-17  Pierre Muller  <muller@ics.u-strasbg.fr>
18357
18358	* configure.ac: Use `ws2_32' library for srv_mingw.
18359	* configure: Regenerate.
18360	* gdbreplay.c: Include winsock2.h instead of winsock.h.
18361	* remote-utils.c: Likewise.
18362
183632010-04-17  H.J. Lu  <hongjiu.lu@intel.com>
18364
18365	* linux-x86-low.c (xmltarget_amd64_linux_no_xml): Define only
18366	if __x86_64__ is defined.
18367
183682010-04-16  Pierre Muller  <muller@ics.u-strasbg.fr>
18369
18370	* configure: Regenerate.
18371
183722010-04-16  Pierre Muller  <muller@ics.u-strasbg.fr>
18373
18374	* server.c (handle_query): Handle 'qGetTIBAddr' query.
18375	* target.h (target_ops): New get_tib_address field.
18376	* win32-low.h (win32_thread_info): Add thread_local_base field.
18377	* win32-low.c (child_add_thread): Add tlb argument.
18378	Set thread_local_base field to TLB.
18379	(get_child_debug_event): Adapt to child_add_thread change.
18380	(win32_get_tib_address): New function.
18381	(win32_target_ops): Set get_tib_address field to
18382	win32_get_tib_address.
18383	* linux-low.c (linux_target_ops): Set get_tib_address field to NULL.
18384
183852010-04-12  Pedro Alves  <pedro@codesourcery.com>
18386
18387	* linux-low.c (linux_mourn): Also remove the process.
18388	* server.c (handle_target_event): Don't remove the process here.
18389	* nto-low.c (nto_mourn): New.
18390	(nto_target_ops): Install it.
18391	* spu-low.c (spu_mourn): New.
18392	(spu_target_ops): Install it.
18393	* win32-low.c (win32_mourn): New.
18394	(win32_target_ops): Install it.
18395
183962010-04-12  Pedro Alves  <pedro@codesourcery.com>
18397
18398	* server.h (buffer_xml_printf): Remove redundant `;'.
18399
184002010-04-12  Pedro Alves  <pedro@codesourcery.com>
18401
18402	* regcache.c (set_register_cache): Invalidate regcaches before
18403	changing the register cache layout.
18404	(regcache_invalidate_one): Allow a NULL regcache.
18405	* linux-x86-low.c (x86_linux_update_xmltarget): Invalidate
18406	regcaches before changing the register cache layout or the target
18407	regsets.
18408
184092010-04-12  H.J. Lu  <hongjiu.lu@intel.com>
18410
18411	* linux-x86-low.c (x86_linux_update_xmltarget): Avoid unused
18412	variable warning on Linux/x86-64.
18413
184142010-04-11  Pedro Alves  <pedro@codesourcery.com>
18415
18416	GDBserver disconnected tracing support.
18417
18418	* linux-low.c (linux_remove_process): Delete.
18419	(add_lwp): Don't set last_resume_kind here.
18420	(linux_kill): Use `mourn'.
18421	(linux_detach): Use `thread_db_detach', and `mourn'.
18422	(linux_mourn): New.
18423	(linux_attach_lwp_1): Adjust comment.
18424	(linux_attach): last_resume_kind moved the thread_info; adjust.
18425	(status_pending_p_callback): Adjust.
18426	(linux_wait_for_event_1): Adjust.
18427	(count_events_callback, select_singlestep_lwp_callback)
18428	(select_event_lwp_callback, cancel_breakpoints_callback)
18429	(db_wants_lwp_stopped, linux_wait_1, need_step_over_p)
18430	(proceed_one_lwp): Adjust.
18431	(linux_async): Add debug output.
18432	(linux_thread_stopped): New.
18433	(linux_pause_all): New.
18434	(linux_target_ops): Install linux_mourn, linux_thread_stopped and
18435	linux_pause_all.
18436	* linux-low.h (struct lwp_info): Delete last_resume_kind field.
18437	(thread_db_free): Delete declaration.
18438	(thread_db_detach, thread_db_mourn): Declare.
18439	* thread-db.c (thread_db_init): Use thread_db_mourn.
18440	(thread_db_free): Delete, split in two.
18441	(disable_thread_event_reporting): New.
18442	(thread_db_detach): New.
18443	(thread_db_mourn): New.
18444
18445	* server.h (struct thread_info) <last_resume_kind>: New field.
18446	<attached>: Add comment.
18447	<gdb_detached>: New field.
18448	(handler_func): Change return type to int.
18449	(handle_serial_event, handle_target_event): Ditto.
18450	(gdb_connected): Declare.
18451	(tracing): Delete.
18452	(disconnected_tracing): Declare.
18453	(stop_tracing): Declare.
18454
18455	* server.c (handle_query) <qSupported>: Report support for
18456	disconnected tracing.
18457	(queue_stop_reply_callback): Account for running threads.
18458	(gdb_wants_thread_stopped): New.
18459	(gdb_wants_all_threads_stopped): New.
18460	(gdb_reattached_process): New.
18461	(handle_status): Clear the `gdb_detached' flag of all processes.
18462	In all-stop, stop all threads.
18463	(main): Be sure to leave tfind mode.  Handle disconnected tracing.
18464	(process_serial_event): If the remote connection breaks, or if an
18465	exit was forced with "monitor exit", force an event loop exit.
18466	Handle disconnected tracing on detach.
18467	(handle_serial_event): Adjust.
18468	(handle_target_event): If GDB isn't connected, forward events back
18469	to the inferior, unless the last process exited, in which case,
18470	exit gdbserver.  Adjust interface.
18471
18472	* remote-utils.c (remote_open): Don't block in accept.  Instead
18473	register an event loop source on the listen socket file
18474	descriptor.  Refactor bits into ...
18475	(listen_desc): ... this new global.
18476	(gdb_connected): ... this new function.
18477	(enable_async_notification): ... this new function.
18478	(handle_accept_event): ... this new function.
18479	(remote_close): Clear remote_desc.
18480
18481	* inferiors.c (add_thread): Set the new thread's last_resume_kind.
18482
18483	* target.h (struct target_ops) <mourn, thread_stopped, pause_all>:
18484	New fields.
18485	(mourn_inferior): Define.
18486	(target_process_qsupported): Avoid the dangling else problem.
18487	(thread_stopped): Define.
18488	(pause_all): Define.
18489	(target_waitstatus_to_string): Declare.
18490	* target.c (target_waitstatus_to_string): New.
18491
18492	* tracepoint.c (tracing): Make extern.
18493	(disconnected_tracing): New.
18494	(stop_tracing): Make extern.  Handle tracing stops due to GDB
18495	disconnecting.
18496	(cmd_qtdisconnected): New.
18497	(cmd_qtstatus): Report disconnected tracing status in trace reply.
18498	(handle_tracepoint_general_set): Handle QTDisconnected.
18499
18500	* event-loop.c (event_handler_func): Change return type to int.
18501	(process_event): Bail out if the event handler wants the event
18502	loop to stop.
18503	(handle_file_event): Ditto.
18504	(start_event_loop): Bail out if the event handler wants the event
18505	loop to stop.
18506
18507	* nto-low.c (nto_target_ops): Adjust.
18508	* spu-low.c (spu_wait): Don't remove the process here.
18509	(spu_target_ops): Adjust.
18510	* win32-low.c (win32_wait): Don't remove the process here.
18511	(win32_target_ops): Adjust.
18512
185132010-04-11  Pedro Alves  <pedro@codesourcery.com>
18514
18515	* regcache.c (realloc_register_cache): Invalidate inferior's
18516	regcache before recreating it.
18517
185182010-04-09  Pedro Alves  <pedro@codesourcery.com>
18519
18520	* tracepoint.c (cmd_qtstatus): Report trace buffer circularity.
18521
185222010-04-09  Stan Shebs  <stan@codesourcery.com>
18523	    Pedro Alves  <pedro@codesourcery.com>
18524
18525	* server.h (LONGEST): New.
18526	(struct thread_info) <while_stepping>: New field.
18527	(unpack_varlen_hex, xrealloc, pulongest, plongest, phex_nz):
18528	Declare.
18529	(initialize_tracepoint, handle_tracepoint_general_set)
18530	(handle_tracepoint_query, tracepoint_finished_step)
18531	(tracepoint_was_hit, release_while_stepping_state_list):
18532	(current_traceframe): Declare.
18533	* server.c (handle_general_set): Handle tracepoint packets.
18534	(read_memory): New.
18535	(write_memory): New.
18536	(handle_search_memory_1): Use read_memory.
18537	(handle_query): Report support for conditional tracepoints, trace
18538	state variables, and tracepoint sources.  Handle tracepoint
18539	queries.
18540	(main): Initialize the tracepoints module.
18541	(process_serial_event): Handle traceframe reads/writes.
18542
18543	* linux-low.c (handle_tracepoints): New.
18544	(linux_wait_1): Call it.
18545	(linux_resume_one_lwp): Handle while-stepping.
18546	(linux_supports_tracepoints, linux_read_pc, linux_write_pc): New.
18547	(linux_target_ops): Install them.
18548	* linux-low.h (struct linux_target_ops) <supports_tracepoints>:
18549	New field.
18550	* linux-x86-low.c (x86_supports_tracepoints): New.
18551	(the_low_target). Install it.
18552
18553	* mem-break.h (delete_breakpoint): Declare.
18554	* mem-break.c (delete_breakpoint): Make external.
18555
18556	* target.h (struct target_ops): Add `supports_tracepoints',
18557	`read_pc', and `write_pc' fields.
18558	(target_supports_tracepoints): Define.
18559	* utils.c (xrealloc, decimal2str, pulongest, plongest, thirty_two)
18560	(phex_nz): New.
18561
18562	* regcache.h (struct regcache) <registers_owned>: New field.
18563	(init_register_cache, regcache_cpy): Declare.
18564	(regcache_read_pc, regcache_write_pc): Declare.
18565	(register_cache_size): Declare.
18566	(supply_regblock): Declare.
18567	* regcache.c (init_register_cache): New.
18568	(new_register_cache): Use it.
18569	(regcache_cpy): New.
18570	(register_cache_size): New.
18571	(supply_regblock): New.
18572	(regcache_read_pc, regcache_write_pc): New.
18573
18574	* tracepoint.c: New.
18575
18576	* Makefile.in (OBS): Add tracepoint.o.
18577	(tracepoint.o): New rule.
18578
185792010-04-08  H.J. Lu  <hongjiu.lu@intel.com>
18580
18581	* Makefile.in (clean): Also remove i386-mmx.c i386-mmx-linux.c.
18582	(i386-mmx.o): New.
18583	(i386-mmx.c): Likewise.
18584	(i386-mmx-linux.o): Likewise.
18585	(i386-mmx-linux.c): Likewise.
18586
18587	* configure.srv (srv_i386_regobj): Add i386-mmx.o.
18588	(srv_i386_linux_regobj): Add i386-mmx-linux.o.
18589	(srv_i386_xmlfiles): Add i386/i386-mmx.xml.
18590	(srv_i386_linux_xmlfiles): Add i386/i386-mmx-linux.xml.
18591
18592	* linux-x86-low.c (init_registers_i386_mmx_linux): New.
18593	(x86_linux_update_xmltarget): Call init_registers_i386_mmx_linux
18594	and return if ptrace PTRACE_GETFPXREGS failed in 32bit.
18595
185962010-04-07  H.J. Lu  <hongjiu.lu@intel.com>
18597
18598	* Makefile.in (clean): Updated.
18599	(i386-avx.o): New.
18600	(i386-avx.c): Likewise.
18601	(i386-avx-linux.o): Likewise.
18602	(i386-avx-linux.c): Likewise.
18603	(amd64-avx.o): Likewise.
18604	(amd64-avx.c): Likewise.
18605	(amd64-avx-linux.o): Likewise.
18606	(amd64-avx-linux.c): Likewise.
18607
18608	* configure.srv (srv_i386_regobj): Add i386-avx.o.
18609	(srv_i386_linux_regobj): Add i386-avx-linux.o.
18610	(srv_amd64_regobj): Add amd64-avx.o.
18611	(srv_amd64_linux_regobj): Add amd64-avx-linux.o.
18612	(srv_i386_32bit_xmlfiles): Add i386/32bit-avx.xml.
18613	(srv_i386_64bit_xmlfiles): Add i386/64bit-avx.xml.
18614	(srv_i386_xmlfiles): Add i386/i386-avx.xml.
18615	(srv_amd64_xmlfiles): Add i386/amd64-avx.xml.
18616	(srv_i386_linux_xmlfiles): Add i386/i386-avx-linux.xml.
18617	(srv_amd64_linux_xmlfiles): Add i386/amd64-avx-linux.xml.
18618
18619	* i387-fp.c: Include "i386-xstate.h".
18620	(i387_xsave): New.
18621	(i387_cache_to_xsave): Likewise.
18622	(i387_xsave_to_cache): Likewise.
18623	(x86_xcr0): Likewise.
18624
18625	* i387-fp.h (i387_cache_to_xsave): Likewise.
18626	(i387_xsave_to_cache): Likewise.
18627	(x86_xcr0): Likewise.
18628
18629	* linux-arm-low.c (target_regsets): Initialize nt_type to 0.
18630	* linux-crisv32-low.c (target_regsets): Likewise.
18631	* linux-m68k-low.c (target_regsets): Likewise.
18632	* linux-mips-low.c (target_regsets): Likewise.
18633	* linux-ppc-low.c (target_regsets): Likewise.
18634	* linux-s390-low.c (target_regsets): Likewise.
18635	* linux-sh-low.c (target_regsets): Likewise.
18636	* linux-sparc-low.c (target_regsets): Likewise.
18637	* linux-xtensa-low.c (target_regsets): Likewise.
18638
18639	* linux-low.c: Include <sys/uio.h>.
18640	(regsets_fetch_inferior_registers): Support nt_type.
18641	(regsets_store_inferior_registers): Likewise.
18642	(linux_process_qsupported): New.
18643	(linux_target_ops): Add linux_process_qsupported.
18644
18645	* linux-low.h (regset_info): Add nt_type.
18646	(linux_target_ops): Add process_qsupported.
18647
18648	* linux-x86-low.c: Include "i386-xstate.h", "elf/common.h"
18649	and <sys/uio.h>.
18650	(init_registers_i386_avx_linux): New.
18651	(init_registers_amd64_avx_linux): Likewise.
18652	(xmltarget_i386_linux_no_xml): Likewise.
18653	(xmltarget_amd64_linux_no_xml): Likewise.
18654	(PTRACE_GETREGSET): Likewise.
18655	(PTRACE_SETREGSET): Likewise.
18656	(x86_fill_xstateregset): Likewise.
18657	(x86_store_xstateregset): Likewise.
18658	(use_xml): Likewise.
18659	(x86_linux_update_xmltarget): Likewise.
18660	(x86_linux_process_qsupported): Likewise.
18661	(target_regsets): Add NT_X86_XSTATE entry and Initialize nt_type.
18662	(x86_arch_setup): Don't call init_registers_amd64_linux nor
18663	init_registers_i386_linux here.  Call
18664	x86_linux_update_xmltarget.
18665	(the_low_target): Add x86_linux_process_qsupported.
18666
18667	* server.c (handle_query): Call target_process_qsupported.
18668
18669	* target.h (target_ops): Add process_qsupported.
18670	(target_process_qsupported): New.
18671
186722010-04-03  Pedro Alves  <pedro@codesourcery.com>
18673
18674	* inferiors.c (add_thread): Set last_status kind to
18675	TARGET_WAITKIND_IGNORE.
18676	* linux-low.c (cancel_breakpoint): Remove unnecessary regcache
18677	fetch.  Use ptid_of.  Avoid unnecessary get_lwp_thread calls.
18678	(linux_wait_1): Move `thread' local definition to block that uses
18679	it.  Don't NULL initialize `event_child'.
18680	(linux_resume_one_thread): Avoid unnecessary get_lwp_thread calls.
18681	Alway set the thread's last_status to TARGET_WAITKIND_IGNORE.
18682	* linux-x86-low.c (x86_breakpoint_at): Read raw memory.
18683
186842010-04-01  Pedro Alves  <pedro@codesourcery.com>
18685
18686	* linux-low.c (get_stop_pc): Don't adjust the PC if stopped with
18687	an extended waitstatus, or by a watchpoint.
18688	(cancel_breakpoints_callback): Don't cancel a breakpoint if the
18689	thread was stepping or has been stopped by a watchpoint.
18690
186912010-04-01  Pedro Alves  <pedro@codesourcery.com>
18692
18693	* mem-break.c (struct raw_breakpoint): New field shlib_disabled.
18694	(set_gdb_breakpoint_at): If GDB is inserting a breakpoint on top
18695	of another, then delete the previous, and validate all
18696	breakpoints.
18697	(validate_inserted_breakpoint): New.
18698	(delete_disabled_breakpoints): New.
18699	(validate_breakpoints): New.
18700	(check_mem_read): Validate breakpoints before trusting their
18701	shadow.  Delete disabled breakpoints.
18702	(check_mem_write): Validate breakpoints before trusting they
18703	should be inserted.  Delete disabled breakpoints.
18704	* mem-break.h (validate_breakpoints):
18705	* server.c (handle_query): Validate breakpoints when we see a
18706	qSymbol query.
18707
187082010-04-01  Pedro Alves  <pedro@codesourcery.com>
18709
18710	* linux-low.c (linux_wait_1): Avoid setting need_step_over is
18711	there's a GDB breakpoint at stop_pc.  Always report a trap to GDB
18712	if we could tell there's a GDB breakpoint at stop_pc.
18713	(need_step_over_p): Don't do a step over if we find a GDB
18714	breakpoint at the resume PC.
18715
18716	* mem-break.c (struct raw_breakpoint): New.
18717	(enum bkpt_type): New type `gdb_breakpoint'.
18718	(struct breakpoint): Delete the `PC', `old_data' and `inserted'
18719	fields.  New field `raw'.
18720	(find_raw_breakpoint_at): New.
18721	(set_raw_breakpoint_at): Handle refcounting.  Create a raw
18722	breakpoint instead.
18723	(set_breakpoint_at): Adjust.
18724	(delete_raw_breakpoint): New.
18725	(release_breakpoint): New.
18726	(delete_breakpoint): Rename to...
18727	(delete_breakpoint_1): ... this.  Add proc parameter.  Use
18728	release_breakpoint.  Return ENOENT.
18729	(delete_breakpoint): Reimplement.
18730	(find_breakpoint_at): Delete.
18731	(find_gdb_breakpoint_at): New.
18732	(delete_breakpoint_at): Delete.
18733	(set_gdb_breakpoint_at): New.
18734	(delete_gdb_breakpoint_at): New.
18735	(gdb_breakpoint_here): New.
18736	(set_reinsert_breakpoint): Use release_breakpoint.
18737	(uninsert_breakpoint): Rename to ...
18738	(uninsert_raw_breakpoint): ... this.
18739	(uninsert_breakpoints_at): Adjust to handle raw breakpoints.
18740	(reinsert_raw_breakpoint): Change parameter type to
18741	raw_breakpoint.
18742	(reinsert_breakpoints_at): Adjust to handle raw breakpoints
18743	instead.
18744	(check_breakpoints): Adjust.  Use release_breakpoint.
18745	(breakpoint_here): Rewrite using find_raw_breakpoint_at.
18746	(breakpoint_inserted_here): Ditto.
18747	(check_mem_read): Adjust to iterate over raw breakpoints instead.
18748	Don't trust the breakpoint's shadow if it is not inserted.
18749	(check_mem_write): Adjust to iterate over raw breakpoints instead.
18750	(delete_all_breakpoints): Adjust.
18751	(free_all_breakpoints): Mark all breakpoints as uninserted, and
18752	use delete_breakpoint_1.
18753
18754	* mem-break.h (breakpoints_supported): Delete declaration.
18755	(set_gdb_breakpoint_at): Declare.
18756	(gdb_breakpoint_here): Declare.
18757	(delete_breakpoint_at): Delete.
18758	(delete_gdb_breakpoint_at): Declare.
18759
18760	* server.h (struct raw_breakpoint): Forward declare.
18761	(struct process_info): New field `raw_breakpoints'.
18762
18763	* linux-x86-low.c (x86_insert_point, x86_remote_point): Handle Z0
18764	breakpoints.
18765
187662010-03-24  Pedro Alves  <pedro@codesourcery.com>
18767
18768	* linux-low.c (status_pending_p_callback): Fix comment.
18769	(linux_wait_for_event_1): Move most of the internal breakpoint
18770	handling from here...
18771	(linux_wait_1): ... to here.
18772	(count_events_callback): New.
18773	(select_singlestep_lwp_callback): New.
18774	(select_event_lwp_callback): New.
18775	(cancel_breakpoints_callback): New.
18776	(select_event_lwp): New.
18777	(linux_wait_1): Simplify internal breakpoint handling.  Give equal
18778	priority to all LWPs that have had events that should be reported
18779	to the client.  Cancel breakpoints when about to reporting the
18780	event to the client, not while stopping lwps.  No longer cancel
18781	finished single-steps here.
18782	(cancel_finished_single_step): Delete.
18783	(cancel_finished_single_steps): Delete.
18784
187852010-03-24  Pedro Alves  <pedro@codesourcery.com>
18786
18787	* mem-break.c (enum bkpt_type): New.
18788	(struct breakpoint): New field `type'.
18789	(set_breakpoint_at): Change return type to struct breakpoint
18790	pointer.  Set type to `other_breakpoint' by default.
18791	(delete_breakpoint): Rewrite, supporting more than one breakpoint
18792	in the breakpoint list.
18793	(delete_reinsert_breakpoints): Only delete reinsert breakpoints.
18794	(reinsert_breakpoint): Rename to ...
18795	(reinsert_raw_breakpoint): ... this.
18796	(reinsert_breakpoints_at): Adjust.
18797	* mem-break.h (struct breakpoint): Declare.
18798	(set_breakpoint_at): Change return type to struct breakpoint
18799	pointer.
18800
188012010-03-24  Pedro Alves  <pedro@codesourcery.com>
18802
18803	* server.c (handle_query): Assign, not compare.
18804
188052010-03-24  Pedro Alves  <pedro@codesourcery.com>
18806
18807	Teach linux gdbserver to step-over-breakpoints.
18808
18809	* linux-low.c (can_hardware_single_step): New.
18810	(supports_breakpoints): New.
18811	(handle_extended_wait): If stopping threads, read the stop pc of
18812	the new cloned LWP.
18813	(get_pc): New.
18814	(get_stop_pc): Add `lwp' parameter.  Handle it.  Bail out if the
18815	low target doesn't support retrieving the PC.
18816	(add_lwp): Set last_resume_kind to resume_continue.
18817	(linux_attach_lwp_1): Adjust comments.  Always set stop_expected.
18818	(linux_attach): Don't clear stop_expected.  Set the lwp's
18819	last_resume_kind to resume_stop.
18820	(linux_detach_one_lwp): Don't check for removed breakpoints.
18821	(check_removed_breakpoint): Delete.
18822	(status_pending_p): Rename to ...
18823	(status_pending_p_callback): ... this.  Don't check for removed
18824	breakpoints.  Don't consider threads that are stopped from GDB's
18825	perspective.
18826	(linux_wait_for_lwp): Always read the stop_pc here.
18827	(cancel_breakpoint): New.
18828	(step_over_bkpt): New global.
18829	(linux_wait_for_event_1): Implement stepping over breakpoints.
18830	(gdb_wants_lwp_stopped): New.
18831	(gdb_wants_all_stopped): New.
18832	(linux_wait_1): Tag threads as gdb-wants-stopped.  Cancel finished
18833	single-step traps here.  Store the thread's last reported target
18834	wait status.
18835	(send_sigstop): Don't clear stop_expected.  Always set it,
18836	instead.
18837	(mark_lwp_dead): Remove reference to pending_is_breakpoint.
18838	(cancel_finished_single_step): New.
18839	(cancel_finished_single_steps): New.
18840	(wait_for_sigstop): Don't cancel finished single-step traps here.
18841	(linux_resume_one_lwp): Don't check for removed breakpoints.
18842	Don't set `step' on non-hardware step archs.
18843	(linux_set_resume_request): Ignore resume_stop requests if already
18844	stopping or stopped.  Set the lwp's last_resume_kind.
18845	(resume_status_pending_p): Don't check for removed breakpoints.
18846	(need_step_over_p): New.
18847	(start_step_over): New.
18848	(finish_step_over): New.
18849	(linux_resume_one_thread): Always queue a sigstop for resume_stop
18850	requests.  Clear the thread's last reported target waitstatus.
18851	Don't use the `suspended' flag.  Don't consider pending breakpoints.
18852	(linux_resume): Start a step-over if necessary.
18853	(proceed_one_lwp): New.
18854	(proceed_all_lwps): New.
18855	(unstop_all_lwps): New.
18856	* linux-low.h (struct lwp_info): Rewrite comment for the
18857	`suspended' flag.  Add the `stop_pc' field.  Delete the
18858	`pending_stop_pc' field.  Tweak the `stepping' flag's comment.
18859	Add `'last_resume_kind' and `need_step_over' fields.
18860	* inferiors.c (struct thread_info): Delete, moved elsewhere.
18861	* mem-break.c (struct breakpoint): Delete `reinserting' flag.
18862	Delete `breakpoint_to_reinsert' field.  New flag `inserted'.
18863	(set_raw_breakpoint_at): New.
18864	(set_breakpoint_at): Rewrite to use it.
18865	(reinsert_breakpoint_handler): Delete.
18866	(set_reinsert_breakpoint): New.
18867	(reinsert_breakpoint_by_bp): Delete.
18868	(delete_reinsert_breakpoints): New.
18869	(uninsert_breakpoint): Rewrite.
18870	(uninsert_breakpoints_at): New.
18871	(reinsert_breakpoint): Rewrite.
18872	(reinsert_breakpoints_at): New.
18873	(check_breakpoints): Rewrite.
18874	(breakpoint_here): New.
18875	(breakpoint_inserted_here): New.
18876	(check_mem_read): Adjust.
18877	* mem-break.h (breakpoints_supported, breakpoint_here)
18878	(breakpoint_inserted_here, set_reinsert_breakpoint): Declare.
18879	(reinsert_breakpoint_by_bp): Delete declaration.
18880	(delete_reinsert_breakpoints): Declare.
18881	(reinsert_breakpoint): Delete declaration.
18882	(reinsert_breakpoints_at): Declare.
18883	(uninsert_breakpoint): Delete declaration.
18884	(uninsert_breakpoints_at): Declare.
18885	(check_breakpoints): Adjust prototype.
18886	* server.h: Adjust include order.
18887	(struct thread_info): Declare here.  Add a `last_status' field.
18888
188892010-03-23  Michael Snyder  <msnyder@vmware.com>
18890
18891	* server.c (crc32): New function.
18892	(handle_query): Add handling for 'qCRC:' request.
18893
188942010-03-23  Pedro Alves  <pedro@codesourcery.com>
18895
18896	* linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR6 if the
18897	lwp had been stopped by a watchpoint.
18898
188992010-03-16  Pedro Alves  <pedro@codesourcery.com>
18900
18901	* server.h (internal_error): Declare.
18902	(gdb_assert, ASSERT_FUNCTION, gdb_assert_fail): Define.
18903	* utils.c (internal_error): New function.
18904
189052010-03-15  Andreas Schwab  <schwab@redhat.com>
18906
18907	* configure.srv: Fix typo setting srv_regobj.
18908
189092010-03-15  Pedro Alves  <pedro@codesourcery.com>
18910
18911	* linux-low.c (fetch_register): Avoid passing a non string literal
18912	format to `error'.
18913	(usr_store_inferior_registers): Ditto.
18914
189152010-03-14  Pedro Alves  <pedro@codesourcery.com>
18916
18917	* linux-low.c (linux_write_memory): Bail out early if peeking
18918	memory failed.
18919
189202010-03-14  Pedro Alves  <pedro@codesourcery.com>
18921
18922	* linux-low.h (struct lwp_info): New fields
18923	`stopped_by_watchpoint' and `stopped_data_address'.
18924	* linux-low.c (linux_wait_for_lwp): Check for watchpoint triggers
18925	here, and cache them in the lwp object.
18926	(wait_for_sigstop): Check stopped_by_watchpoint lwp field
18927	directly.
18928	(linux_resume_one_lwp): Clear the lwp's stopped_by_watchpoint
18929	field.
18930	(linux_stopped_by_watchpoint): Rewrite.
18931	(linux_stopped_data_address): Rewrite.
18932
189332010-03-06  Simo Melenius  <simo.melenius@iki.fi>
18934
18935	* linux-low.c (linux_wait_for_lwp): Fetch the regcache after
18936	switching the current inferior, not before.
18937
189382010-03-01  H.J. Lu  <hongjiu.lu@intel.com>
18939
18940	* Makefile.in (clean): Replace reg-i386.c, reg-x86-64.c,
18941	reg-i386-linux.c and reg-x86-64-linux.c with i386.c, amd64.c,
18942	i386-linux.c and amd64-linux.c.
18943	(reg-i386.o): Removed.
18944	(reg-i386.c): Likewise.
18945	(reg-i386-linux.o): Likewise.
18946	(reg-i386-linux.c): Likewise.
18947	(reg-x86-64.o): Likewise.
18948	(reg-x86-64.c): Likewise.
18949	(reg-x86-64-linux.o): Likewise.
18950	(reg-x86-64-linux.c): Likewise.
18951	(i386.o): New.
18952	(i386.c): Likewise.
18953	(i386-linux.o): Likewise.
18954	(i386-linux.c): Likewise.
18955	(amd64.o): Likewise.
18956	(amd64.c): Likewise.
18957	(amd64-linux.o): Likewise.
18958	(amd64-linux.c): Likewise.
18959
18960	* configure.srv (srv_i386_regobj): New.
18961	(srv_i386_linux_regobj): Likewise.
18962	(srv_amd64_regobj): Likewise.
18963	(srv_amd64_linux_regobj): Likewise.
18964	(srv_i386_32bit_xmlfiles): Likewise.
18965	(srv_i386_64bit_xmlfiles): Likewise.
18966	(srv_i386_xmlfiles): Likewise.
18967	(srv_amd64_xmlfiles): Likewise.
18968	(srv_i386_linux_xmlfiles): Likewise.
18969	(srv_amd64_linux_xmlfiles): Likewise.
18970	(i[34567]86-*-cygwin*): Set srv_regobj to $srv_i386_regobj.  Set
18971	srv_xmlfiles to $srv_i386_xmlfiles.
18972	(i[34567]86-*-mingw32ce*): Likewise.
18973	(i[34567]86-*-mingw*): Likewise.
18974	(i[34567]86-*-nto*): Likewise.
18975	(i[34567]86-*-linux*): Set srv_regobj to $srv_i386_linux_regobj
18976	and $srv_amd64_linux_regobj.  Set srv_xmlfiles to
18977	$srv_i386_linux_xmlfiles and $srv_amd64_linux_xmlfiles.
18978	(x86_64-*-linux*): Likewise.
18979
18980	* linux-x86-low.c (init_registers_x86_64_linux): Removed.
18981	(init_registers_amd64_linux): New.
18982	(x86_arch_setup): Replace init_registers_x86_64_linux with
18983	init_registers_amd64_linux.
18984
189852010-02-23  Maxim Kuvyrkov  <maxim@codesourcery.com>
18986
18987	* configure.ac: Check for libdl.  If it is not available link against
18988	static libthread_db.
18989	* configure: Regenerate.
18990
189912010-02-22  Pedro Alves  <pedro@codesourcery.com>
18992
18993	PR9605
18994
18995	* i386-low.c (i386_length_and_rw_bits): Throw a fatal error if
18996	handing a read watchpoint.
18997	(i386_low_insert_watchpoint): Read watchpoints aren't supported.
18998
189992010-02-12  Doug Evans  <dje@google.com>
19000
19001	* linux-low.c (linux_supports_tracefork_flag): Document.
19002	(linux_look_up_symbols): Add comment.
19003
190042010-02-03  H.J. Lu  <hongjiu.lu@intel.com>
19005
19006	* regcache.c (supply_register): Clear regcache if buf is NULL.
19007
190082010-02-02  Nicolas Roche  <roche@sourceware.org>
19009	    Joel Brobecker  <brobecker@adacore.com>
19010
19011	* inferiors.c (find_inferior): Add function documentation.
19012	(unloaded_dll): Handle the case where the unloaded dll has not
19013	been previously registered in the dll list.
19014
190152010-02-01  Daniel Jacobowitz  <dan@codesourcery.com>
19016
19017	* linux-arm-low.c (thumb_breakpoint_len): Delete.
19018	(thumb2_breakpoint): New.
19019	(arm_breakpoint_at): Check for Thumb-2 breakpoints.
19020
190212010-01-29  Daniel Jacobowitz  <dan@codesourcery.com>
19022
19023	* linux-low.c (get_stop_pc): Check for SIGTRAP.
19024	(linux_wait_for_event_1): Handle SIGILL and SIGSEGV as possible
19025	breakpoints.
19026
190272010-01-21  Pedro Alves  <pedro@codesourcery.com>
19028
19029	* linux-ppc-low.c (ppc_arch_setup): Adjust to regcache changes.
19030
190312010-01-21  Jan Kratochvil  <jan.kratochvil@redhat.com>
19032
19033	* linux-s390-low.c (s390_collect_ptrace_register)
19034	(s390_supply_ptrace_register): Adjust it for the new regcache parameter.
19035
190362010-01-21  Doug Evans  <dje@google.com>
19037
19038	* linux-low.c (PTRACE_ARG3_TYPE): Change from long to void*.
19039	(PTRACE_ARG4_TYPE): New macro.
19040	(handle_extended_wait): Cast ptrace arg4 to PTRACE_ARG4_TYPE.
19041	(linux_wait_for_event_1, linux_resume_one_lwp): Ditto.
19042	(fetch_register): Cast to uintptr_t before casting to PTRACE_ARG3_TYPE.
19043	(usr_store_inferior_registers): Ditto.
19044	(linux_read_memory, linux_write_memory): Ditto.
19045	(linux_test_for_tracefork): Ditto.
19046
19047	* linux-arm-low.c: Remove redundant include of gdb_proc_service.h.
19048	Only include elf.h if gdb_proc_service.h didn't include linux/elf.h.
19049
190502010-01-21  Pedro Alves  <pedro@codesourcery.com>
19051
19052	* proc-service.c (ps_lgetregs): Don't refetch registers from the
19053	target.
19054
190552010-01-21  Pedro Alves  <pedro@codesourcery.com>
19056
19057	* spu-low.c (spu_fetch_registers, spu_store_registers): Change
19058	prototype to take a regcache.  Adjust.
19059
190602010-01-20  Pedro Alves  <pedro@codesourcery.com>
19061
19062	* regcache.h (struct thread_info): Forward declare.
19063	(struct regcache): New.
19064	(new_register_cache): Adjust prototype.
19065	(get_thread_regcache): Declare.
19066	(free_register_cache): Adjust prototype.
19067	(registers_to_string, registers_from_string): Ditto.
19068	(supply_register, supply_register_by_name, collect_register)
19069	(collect_register_as_string, collect_register_by_name): Ditto.
19070	* regcache.c (struct inferior_regcache_data): Delete.
19071	(get_regcache): Rename to ...
19072	(get_thread_regcache): ... this.  Adjust.  Switch inferior before
19073	fetching registers.
19074	(regcache_invalidate_one): Adjust.
19075	(regcache_invalidate): Fix prototype.
19076	(new_register_cache): Return the new register cache.
19077	(free_register_cache): Change prototype.
19078	(realloc_register_cache): Adjust.
19079	(registers_to_string): Change prototype to take a regcache.  Adjust.
19080	(registers_from_string): Ditto.
19081	(register_data): Ditto.
19082	(supply_register): Ditto.
19083	(supply_register_by_name): Ditto.
19084	(collect_register): Ditto.
19085	(collect_register_as_string): Ditto.
19086	(collect_register_by_name): Ditto.
19087	* server.c (process_serial_event): Adjust.
19088	* linux-low.h (regset_fill_func, regset_store_func): Change
19089	prototype.
19090	(get_pc, set_pc, collect_ptrace_register, supply_ptrace_register):
19091	Change prototype.
19092	* linux-low.c (get_stop_pc): Adjust.
19093	(check_removed_breakpoint): Adjust.
19094	(linux_wait_for_event): Adjust.
19095	(linux_resume_one_lwp): Adjust.
19096	(fetch_register): Add regcache parameter.  Adjust.
19097	(usr_store_inferior_registers): Ditto.
19098	(regsets_fetch_inferior_registers): Ditto.
19099	(regsets_store_inferior_registers): Ditto.
19100	(linux_fetch_registers, linux_store_registers): Ditto.
19101	* i387-fp.c (i387_cache_to_fsave): Change prototype to take a
19102	regcache.  Adjust.
19103	(i387_fsave_to_cache, i387_cache_to_fxsave, i387_fxsave_to_cache):
19104	Ditto.
19105	* i387-fp.h (i387_cache_to_fsave, i387_fsave_to_cache): Change
19106	prototype to take a regcache.
19107	(i387_cache_to_fxsave, i387_fxsave_to_cache): Ditto.
19108	* remote-utils.c (convert_ascii_to_int, outreg)
19109	(prepare_resume_reply): Change prototype to take a regcache.
19110	Adjust.
19111	* target.h (struct target_ops) <fetch_registers, store_registers>:
19112	Change prototype to take a regcache.
19113	(fetch_inferior_registers, store_inferior_registers): Change
19114	prototype to take a regcache.  Adjust.
19115	* proc-service.c (ps_lgetregs): Adjust.
19116	* linux-x86-low.c (x86_fill_gregset, x86_store_gregset)
19117	(x86_fill_fpregset, x86_store_fpregset, x86_fill_fpxregset)
19118	(x86_store_fpxregset, x86_get_pc, x86_set_pc): Change prototype to
19119	take a regcache.  Adjust.
19120	* linux-arm-low.c (arm_fill_gregset, arm_store_gregset)
19121	(arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
19122	(arm_store_vfpregset, arm_get_pc, arm_set_pc):
19123	(arm_breakpoint_at): Change prototype to take a regcache.  Adjust.
19124	* linux-cris-low.c (cris_get_pc, cris_set_pc)
19125	(cris_cannot_fetch_register):
19126	(cris_breakpoint_at): Change prototype to take a regcache.
19127	Adjust.
19128	* linux-crisv32-low.c (cris_get_pc, cris_set_pc,
19129	cris_reinsert_addr, cris_write_data_breakpoint): Change prototype
19130	to take a regcache.  Adjust.
19131	(cris_breakpoint_at, cris_insert_point, cris_remove_point):
19132	Adjust.
19133	* linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Change prototype to
19134	take a regcache.  Adjust.
19135	* linux-m68k-low.c (m68k_fill_gregset, m68k_store_gregset)
19136	(m68k_fill_fpregset, m68k_store_fpregset, m68k_get_pc,
19137	(m68k_set_pc): Change prototype to take a regcache.  Adjust.
19138	* linux-mips-low.c (mips_get_pc):
19139	(mips_set_pc): Change prototype to take a regcache.  Adjust.
19140	(mips_reinsert_addr): Adjust.
19141	(mips_collect_register): Change prototype to take a regcache.
19142	Adjust.
19143	(mips_supply_register):
19144	(mips_collect_register_32bit, mips_supply_register_32bit)
19145	(mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
19146	(mips_store_fpregset): Ditto.
19147	* linux-ppc-low.c (ppc_supply_ptrace_register)
19148	(ppc_supply_ptrace_register): Ditto.
19149	(parse_spufs_run): Adjust.
19150	(ppc_get_pc, ppc_set_pc, ppc_fill_gregset, ppc_fill_vsxregset)
19151	(ppc_store_vsxregset, ppc_fill_vrregset, ppc_store_vrregset)
19152	(ppc_fill_evrregset, ppc_store_evrregset): Change prototype to
19153	take a regcache.  Adjust.
19154	* linux-s390-low.c (s390_collect_ptrace_register)
19155	(s390_supply_ptrace_register, s390_fill_gregset, s390_get_pc)
19156	(s390_set_pc): Change prototype to take a regcache.  Adjust.
19157	(s390_arch_setup): Adjust.
19158	* linux-sh-low.c (sh_get_pc, sh_breakpoint_at)
19159	(sh_fill_gregset): Change prototype to take a regcache.  Adjust.
19160	* linux-sparc-low.c (sparc_fill_gregset_to_stack)
19161	(sparc_fill_gregset, sparc_store_gregset_from_stack)
19162	(sparc_store_gregset, sparc_get_pc): Change prototype to take a
19163	regcache.  Adjust.
19164	(sparc_breakpoint_at): Adjust.
19165	* linux-xtensa-low.c (xtensa_fill_gregset):
19166	(xtensa_store_gregset):
19167	(xtensa_fill_xtregset, xtensa_store_xtregset, xtensa_get_pc)
19168	(xtensa_set_pc): Change prototype to take a regcache.  Adjust.
19169	* nto-low.c (nto_fetch_registers, nto_store_registers): Change
19170	prototype to take a regcache.  Adjust.
19171	* win32-arm-low.c (arm_fetch_inferior_register)
19172	(arm_store_inferior_register): Change prototype to take a
19173	regcache.  Adjust.
19174	* win32-i386-low.c (i386_fetch_inferior_register)
19175	(i386_store_inferior_register): Change prototype to take a
19176	regcache.  Adjust.
19177	* win32-low.c (child_fetch_inferior_registers)
19178	(child_store_inferior_registers): Change prototype to take a
19179	regcache.  Adjust.
19180	(win32_wait): Adjust.
19181	(win32_fetch_inferior_registers): Change prototype to take a
19182	regcache.  Adjust.
19183	(win32_store_inferior_registers): Adjust.
19184	* win32-low.h (struct win32_target_ops) <fetch_inferior_register,
19185	store_inferior_register>: Change prototype to take a regcache.
19186
191872010-01-20  Doug Evans  <dje@google.com>
19188
19189	* linux-low.c (linux_create_inferior): Wrap use of __SIGRTMIN in
19190	#ifdef.
19191	(linux_wait_for_event1, linux_init_signals): Ditto.
19192	(W_STOPCODE): Provide definition if missing.
19193
191942010-01-13  Vladimir Prus  <vladimir@codesourcery.com>
19195
19196	* linux-low.c (linux_core_of_thread): New.
19197	(compare_ints, show_process, list_threads): New.
19198	(linux_qxfer_osdata): Report threads and cores.
19199	(linux_target_op): Register linux_core_of_thread.
19200	* remote-utils.c (prepare_resume_reply): Report the core.
19201	(buffer_xml_printf): Support %d specifier.
19202	* server.c (handle_threads_qxfer_proper, handle_threads_qxfer):
19203	New.
19204	(handle_query): Handle qXfer:threads.  Announce availability
19205	thereof.
19206	* target.h (struct target_ops): New field core_of_thread.
19207
192082010-01-04  Ulrich Weigand  <uweigand@de.ibm.com>
19209
19210	* Makefile.in (clean): Remove new generated files.
19211	(reg-s390.o, reg-s390.c): Remove rules.
19212	(reg-s390x.o, reg-s390x.c): Likewise.
19213	(s390-linux32.o, s390-linux32.c): Add rules.
19214	(s390-linux64.o, s390-linux64.c): Likewise.
19215	(s390x-linux64.o, s390x-linux64.c): Likewise.
19216	* configure.srv (s390*-*-linux*): Update srv_regobj and srv_xmlfiles.
19217	* linux-s390-low.c: Include <elf.h>.
19218	(HWCAP_S390_HIGH_GPRS): Define if undefined.
19219	(init_registers_s390): Remove prototype.
19220	(init_registers_s390x): Likewise.
19221	(init_registers_s390_linux32): Add prototype.
19222	(init_registers_s390_linux64): Likewise.
19223	(init_registers_s390x_linux64): Likewise.
19224	(s390_num_regs_3264): New define.
19225	(s390_regmap_3264): New global variable.
19226	(s390_cannot_fetch_register): Remove obsolete check.
19227	(s390_cannot_store_register): Likewise.
19228	(s390_collect_ptrace_register): Handle upper/lower register halves.
19229	(s390_supply_ptrace_register): Likewise.
19230	(s390_fill_gregset): Update to register number changes.
19231	(s390_get_hwcap): New routine.
19232	(s390_arch_setup): Detect 32-bit process running on 64-bit system.
19233	Install appropriate regmap and register set.
19234
192352010-01-01  Joel Brobecker  <brobecker@adacore.com>
19236
19237	* server.c (gdbserver_version): Update copyright year to 2010.
19238	* gdbreplay.c (gdbreplay_version): Likewise.
19239
192402009-12-28  Doug Evans  <dje@google.com>
19241
19242	* linux-low.c: Delete inclusion of ansidecl.h, elf/common.h,
19243	elf/external.h.  Include <elf.h> instead but only if necessary.
19244
192452009-12-28  Pedro Alves  <pedro@codesourcery.com>
19246
19247	* linux-low.c (linux_remove_process): Remove `detaching'
19248	parameter.  Don't release/detach from thread_db here.
19249	(linux_kill): Release/detach from thread_db here, ...
19250	(linux_detach): ... and here, before actually detaching.
19251	(linux_wait_1): ... and here, when a process exits.
19252	* thread-db.c (any_thread_of): New.
19253	(thread_db_free): Switch the current inferior to a thread of the
19254	passed in process.
19255
192562009-12-21  Doug Evans  <dje@google.com>
19257
19258	* linux-x86-low.c: Delete outdated comment about Elf32_Phdr.
19259
19260	* linux-low.c (kill_lwp): Use __NR_tkill instead of SYS_tkill.
19261	Move definition of tkill_failed to ifdef __NR_tkill to avoid gcc
19262	warning ifndef __NR_tkill.  Move setting of errno there too.
19263	Delete unnecessary resetting of errno after syscall.
19264	Minor comment changes to match gdb/linux-nat.c:kill_lwp.
19265
19266	* configure.ac: Check for dladdr.
19267	* config.in: Regenerate.
19268	* configure: Regenerate.
19269	* thread-db.c (dladdr_to_soname): Only define ifdef HAVE_DLADDR.
19270	(try_thread_db_load): Update.
19271
19272	* linux-low.c (my_waitpid): Delete unnecessary prototype.
19273
192742009-12-18  Doug Evans  <dje@google.com>
19275
19276	* event-loop.c: Include unistd.h if it exists.
19277
19278	* linux-low.c (my_waitpid): Move definition away from being in
19279	between linux_tracefork_child/linux_test_for_tracefork.
19280
19281	* gdb_proc_service.h (psaddr_t): Fix type.
19282	* thread-db.c (thread_db_info.td_thr_tls_get_addr_p): Fix
19283	signature to match glibc.
19284
192852009-12-16  Doug Evans  <dje@google.com>
19286
19287	* linux-low.c (linux_read_memory): Fix argument to read.
19288
192892009-11-26  Pedro Alves  <pedro@codesourcery.com>
19290
19291	* win32-low.c (get_child_debug_event): On EXIT_THREAD_DEBUG_EVENT
19292	events, don't leave current_inferior pointing at null.
19293
192942009-11-26  Pedro Alves  <pedro@codesourcery.com>
19295
19296	* win32-low.c (LOG): Delete.
19297	(OUTMSG): Output to stderr.
19298	(OUTMSG2): Conditionalize on `debug_threads' variable, instead of
19299	on compile time LOG macro.
19300	(win32_wait): Fix debug output.
19301
193022009-11-26  Pedro Alves  <pedro@codesourcery.com>
19303
19304	* win32-low.c (win32_add_one_solib): If the dll name is
19305	"ntdll.dll", prepend the system directory to the dll path.
19306
193072009-11-17  Daniel Jacobowitz  <dan@codesourcery.com>
19308
19309	* m68k-tdep.c (m68k_gdbarch_init): Reuse previous initialization.
19310
193112009-11-17  Nathan Sidwell  <nathan@codesourcery.com>
19312	    Vladimir Prus  <vladimir@codesourcery.com>
19313
19314	* Makefile.in (reg-cf.o, reg-cf.c): New targets.
19315	* configure.ac: Check for __mcoldfire__ and set
19316	gdb_cv_m68k_is_coldfire.
19317	* configure.srv: Use gdb_cv_m68k_is_coldfire to select between
19318	reg-cf.o and reg-m68k.o.
19319	* configure: Regenerated.
19320
193212009-11-16  Pedro Alves  <pedro@codesourcery.com>
19322
19323	* linux-low.c (linux_remove_process): Add `detaching' parameter.
19324	Pass it to thread_db_free.
19325	(linux_kill, linux_detach, linux_wait_1): Adjust to pass the
19326	proper `detaching' argument to linux_remove_process.
19327	* linux-low.h (thread_db_free): Add `detaching' parameter.
19328	* thread-db.c (thread_db_init): Pass false as `detaching' argument
19329	to thread_db_free.
19330	(thread_db_free): Add `detaching' parameter.  Only
19331	call td_ta_clear_event if detaching from process.
19332
193332009-11-12  Maxim Kuvyrkov  <maxim@codesourcery.com>
19334
19335	* thread-db.c (thread_db_free): Fix typo.
19336
193372009-11-11  Paul Pluzhnikov  <ppluzhnikov@google.com>
19338
19339	PR gdb/10838
19340	* thread-db.c (thread_db_free): Call td_ta_clear_event.
19341
193422009-11-03  Nathan Sidwell  <nathan@codesourcery.com>
19343
19344	* configure.ac (i[34567]86-*): Check if we're targetting x86-64
19345	with an i686 compiler.
19346	* configure.srv (i[34567]86-*-linux*): Pull in x86-64 handling if
19347	needed.
19348	* configure: Rebuilt.
19349
193502009-10-29  Sandra Loosemore  <sandra@codesourcery.com>
19351
19352	PR gdb/10783
19353
19354	* server.c (handle_search_memory_1): Correct read_addr initialization
19355	in loop for searching subsequent chunks.
19356
193572009-10-29  Paul Pluzhnikov  <ppluzhnikov@google.com>
19358
19359	* configure.ac: New --with-libthread-db option.
19360	* thread-db.c: Allow direct dependence on libthread_db.
19361	(thread_db_free): Adjust.
19362	* config.in: Regenerate.
19363	* configure: Likewise.
19364
193652009-10-28  Paul Pluzhnikov  <ppluzhnikov@google.com>
19366
19367	PR gdb/10757
19368	* thread-db.c (attach_thread): New function.
19369	(maybe_attach_thread): Return success/failure.
19370	(find_new_threads_callback): Adjust.
19371	(thread_db_find_new_threads): Loop until no new threads.
19372
193732009-10-13  Pedro Alves  <pedro@codesourcery.com>
19374
19375	* proc-service.c (ps_lgetregs): Formatting.
19376
193772009-10-08  Paul Pluzhnikov  <ppluzhnikov@google.com>
19378
19379	* acinclude.m4: (SRV_CHECK_THREAD_DB, SRV_CHECK_TLS_GET_ADDR): Remove.
19380	* configure.ac: Adjust.
19381	* linux-low.h (struct process_info_private): Move members to struct
19382	thread_db.
19383	(thread_db_free, thread_db_handle_monitor_command): New prototype.
19384	* linux-low.c (linux_remove_process): Adjust.
19385	(linux_wait_for_event_1, linux_look_up_symbols): Likewise.
19386	* server.c (handle_query): Move code ...
19387	(handle_monitor_command): ... here. New function.
19388	* target.h (struct target_ops): New member.
19389	* thread-db.c (struct thread_db): New.
19390	(libthread_db_search_path): New variable.
19391	(thread_db_create_event, thread_db_enable_reporting)
19392	(find_one_thread, maybe_attach_thread, find_new_threads_callback)
19393	(thread_db_find_new_threads, (thread_db_get_tls_address): Adjust.
19394	(try_thread_db_load_1, dladdr_to_soname): New functions.
19395	(try_thread_db_load, thread_db_load_search): New functions.
19396	(thread_db_init): Search for libthread_db.
19397	(thread_db_free): New function.
19398	(thread_db_handle_monitor_command): Likewise.
19399	* config.in: Regenerate.
19400	* configure: Regenerate.
19401
194022009-09-27  Ulrich Weigand  <uweigand@de.ibm.com>
19403
19404	* spu-low.c (spu_kill): Wait for inferior to terminate.
19405	Call clear_inferiors.
19406	(spu_detach): Call clear_inferiors.
19407
194082009-08-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
19409
19410	* aclocal.m4: Regenerate.
19411	* config.in: Likewise.
19412	* configure: Likewise.
19413
194142009-07-31  Ulrich Weigand  <uweigand@de.ibm.com>
19415
19416	* linux-ppc-low.c (INSTR_SC, NR_spu_run): Define.
19417	(parse_spufs_run): New function.
19418	(ppc_get_pc, ppc_set_pc): Detect and handle SPU PC.
19419	(ppc_breakpoint_at): Handle SPU breakpoints.
19420
194212009-07-31  Ulrich Weigand  <uweigand@de.ibm.com>
19422
19423	* linux-low.c: Include <sys/stat.h> and <sys/vfs.h>.
19424	(SPUFS_MAGIC): Define.
19425	(spu_enumerate_spu_ids): New function.
19426	(linux_qxfer_spu): New function.
19427	(linux_target_ops): Install linux_qxfer_spu.
19428
194292009-07-31  Ulrich Weigand  <uweigand@de.ibm.com>
19430
19431	* configure.srv (powerpc*-*-linux*): Add powerpc-cell32l.o
19432	and powerpc-cell64l.o to srv_regobj.  Add rs6000/powerpc-cell32l.xml
19433	and rs6000/powerpc-cell64l.xml to srv_xmlfiles.
19434	* Makefile.in (powerpc-cell32l.o, powerpc-cell32l.c): New rules.
19435	(powerpc-cell64l.o, powerpc-cell64l.c): Likewise.
19436	(clean): Handle powerpc-cell32l.c and powerpc-cell64l.c.
19437	* linux-ppc-low.c (PPC_FEATURE_CELL): Define.
19438	(init_registers_powerpc_cell32l): Add prototype.
19439	(init_registers_powerpc_cell64l): Likewise.
19440	(ppc_arch_setup): Detect Cell/B.E. architecture.
19441
194422009-07-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
19443
19444	* Makefile.in (datarootdir): New variable.
19445
194462009-07-28  Daniel Jacobowitz  <dan@codesourcery.com>
19447
19448	* linux-low.c (linux_write_memory): Update debugging output.
19449	* Makefile.in (clean): Add new descriptions.
19450	(arm-with-vfpv2.o, arm-with-vfpv2.c, arm-with-vfpv3.o)
19451	(arm-with-vfpv3.c, arm-with-neon.o, arm-with-neon.c): New rules.
19452	* configure.srv: Add new files for arm*-*-linux*.
19453	* linux-arm-low.c: Add new declarations.
19454	(PTRACE_GETVFPREGS, PTRACE_SETVFPREGS): Define if undefined.
19455	(arm_hwcap, HWCAP_VFP, HWCAP_IWMMXT, HWCAP_NEON, HWCAP_VFPv3)
19456	(HWCAP_VFPv3D16): New.
19457	(arm_fill_wmmxregset, arm_store_wmmxregset): Check HWCAP_IWMMXT
19458	instead of __IWMMXT__.
19459	(arm_fill_vfpregset, arm_store_vfpregset, arm_get_hwcap)
19460	(arm_arch_setup): New.
19461	(target_regsets): Remove #ifdef.  Add VFP regset.
19462	(the_low_target): Use arm_arch_setup.
19463
194642009-07-28  Daniel Jacobowitz  <dan@codesourcery.com>
19465
19466	* linux-low.c (linux_kill_one_lwp): Adjust kernel workaround to skip
19467	the main thread again.
19468
194692009-07-06  Aleksandar Ristovski  <aristovski@qnx.com>
19470
19471	Adding Neutrino gdbserver.
19472	* configure: Regenerated.
19473	* configure.ac: Add case for srv_qnx and set LIBS accordingly.
19474	* configure.srv (i[34567]86-*-nto*): New target.
19475	* nto-low.c, nto-low.h, nto-x86-low.c: New files.
19476	* remote-utils.c [__QNX__]: Include sys/iomgr.h
19477	(nto_comctrl) [__QNX__]: New function.
19478	(enable_async_io, disable_async_io) [__QNX__]: Call nto_comctrl.
19479
194802009-07-05  Danny Backx  <dannybackx@users.sourceforge.net>
19481
19482	* configure.srv (i[34567]86-*-mingw32ce*): Add i386-low.o to
19483	srv_tgtobj.
19484
194852009-07-04  Danny Backx  <dannybackx@users.sourceforge.net>
19486	    Pedro Alves  <pedro@codesourcery.com>
19487
19488	* win32-i386-low.c (i386_get_thread_context): Handle systems that
19489	don't support CONTEXT_EXTENDED_REGISTERS.
19490	(i386_win32_breakpoint, i386_win32_breakpoint_len): New.
19491	(the_low_target): Install them.
19492	* win32-low.c (get_child_debug_event): Handle WaitForDebugEvent
19493	failing with ERROR_PIPE_NOT_CONNECTED.
19494
194952009-06-30  Doug Evans  <dje@google.com>
19496	    Pierre Muller  <muller@ics.u-strasbg.fr>
19497
19498	Add h/w watchpoint support to x86-linux, win32-i386.
19499	* Makefile.in (SFILES): Add i386-low.c
19500	(i386_low_h): Define.
19501	(i386-low.o): Add dependencies.
19502	(linux-x86-low.o): Add i386-low.h dependency.
19503	(win32-i386-low.o): Ditto.
19504	* i386-low.c: New file.
19505	* i386-low.h: New file.
19506	* configure.srv (i[34567]86-*-cygwin*): Add i386-low.o to srv_tgtobj.
19507	(i[34567]86-*-linux*, i[34567]86-*-mingw*, x86_64-*-linux*): Ditto.
19508	* linux-low.c (linux_add_process): Initialize arch_private.
19509	(linux_remove_process): Free arch_private.
19510	(add_lwp): Initialize arch_private.
19511	(delete_lwp): Free arch_private.
19512	(linux_resume_one_lwp): Call the_low_target.prepare_to_resume if
19513	provided.
19514	* linux-low.h (process_info_private): New member arch_private.
19515	(lwp_info): New member arch_private.
19516	(linux_target_ops): New members new_process, new_thread,
19517	prepare_to_resume.
19518	(ptid_of): New macro.
19519	* linux-x86-low.c: Include stddef.h, i386-low.h.
19520	(arch_process_info): New struct.
19521	(arch_lwp_info): New struct.
19522	(x86_linux_dr_get, x86_linux_dr_set): New functions.
19523	(i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
19524	(i386_dr_low_get_status): New function.
19525	(x86_insert_point, x86_remove_point): New functions.
19526	(x86_stopped_by_watchpoint): New function.
19527	(x86_stopped_data_address): New function.
19528	(x86_linux_new_process, x86_linux_new_thread): New functions.
19529	(x86_linux_prepare_to_resume): New function.
19530	(the_low_target): Add entries for insert_point, remove_point,
19531	stopped_by_watchpoint, stopped_data_address, new_process, new_thread,
19532	prepare_to_resume.
19533	* server.c (debug_hw_points): New global.
19534	(monitor_show_help): Document set debug-hw-points.
19535	(handle_query): Process "set debug-hw-points".
19536	* server.h (debug_hw_points): Declare.
19537	(paddress): Declare.
19538	* utils.c (NUMCELLS, CELLSIZE): New macros.
19539	(get_sell, xsnprintf, paddress): New functions.
19540	* win32-arm-low.c (the_low_target): Add entries for insert_point,
19541	remove_point, stopped_by_watchpoint, stopped_data_address.
19542	* win32-i386-low.c: Include i386-low.h.
19543	(debug_reg_state): Replaces dr.
19544	(i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
19545	(i386_dr_low_get_status): New function.
19546	(i386_insert_point, i386_remove_point): New functions.
19547	(i386_stopped_by_watchpoint): New function.
19548	(i386_stopped_data_address): New function.
19549	(i386_initial_stuff): Update.
19550	(get_thread_context,set_thread_context,i386_thread_added): Update.
19551	(the_low_target): Add entries for insert_point,
19552	remove_point, stopped_by_watchpoint, stopped_data_address.
19553	* win32-low.c (win32_insert_watchpoint): New function.
19554	(win32_remove_watchpoint): New function.
19555	(win32_stopped_by_watchpoint): New function.
19556	(win32_stopped_data_address): New function.
19557	(win32_target_ops): Add entries for insert_watchpoint,
19558	remove_watchpoint, stopped_by_watchpoint, stopped_data_address.
19559	* win32-low.h (win32_target_ops): New members insert_point,
19560	remove_point, stopped_by_watchpoint, stopped_data_address.
19561
195622009-06-25  Pedro Alves  <pedro@codesourcery.com>
19563
19564	* server.c (process_serial_event): Re-return unsupported, not
19565	error, if the type isn't recognized.  Re-allow supporting only
19566	insert or remove packets.  Also call require_running for
19567	breakpoints.  Add missing break statement to default case.  Tidy.
19568	* target.h (struct target_ops): Rename insert_watchpoint to
19569	insert_point, and remove_watchpoint to remove_point.
19570
19571	* linux-low.h (struct linux_target_ops): Likewise.
19572	* linux-low.c (linux_insert_watchpoint): Rename to ...
19573	(linux_insert_point): ... this.  Adjust.
19574	(linux_remove_watchpoint): Rename to ...
19575	(linux_remove_point): ... this.  Adjust.
19576	(linux_target_ops): Adjust.
19577	* linux-crisv32-low.c (cris_insert_watchpoint): Rename to ...
19578	(cris_insert_point): ... this.
19579	(cris_remove_watchpoint): Rename to ...
19580	(cris_remove_point): ... this.
19581	(the_low_target): Adjust.
19582
195832009-06-24  Pierre Muller  <muller@ics.u-strasbg.fr>
19584
19585	* server.c (handle_v_kill): Pass signal_pid to
19586	kill_inferior if multi_process is zero.
19587
195882009-06-23  Aleksandar Ristovski  <aristovski@qnx.com>
19589
19590	* server.c (process_serial_event): Add support for Z0 and Z1 packet.
19591	* target.h (target_ops): Comment for *_watchpoint to make it clear
19592	the functions can get types '0' and '1'.
19593
195942009-06-22  Aleksandar Ristovski  <aristovski@qnx.com>
19595
19596	* linux-low.c (usr_fetch_inferior_registers): Remove check for regno 0.
19597	* proc-service.c (ps_lgetregs): Pass -1 to fetch all registers.
19598	* regcache.c (get_regcache): Likewise.
19599	* spu-low.c (spu_fetch_registers): Remove 0 to -1 conversion.
19600	* win32-low.c (child_fetch_inferior_registers): Remove check for
19601	regno 0.
19602
196032009-06-19  Aleksandar Ristovski  <aristovski@qnx.com>
19604	    Pedro Alves <pedro@codesourcery.com>
19605
19606	* target.h (struct target_ops) <supports_multi_process>: New
19607	callback.
19608	(target_supports_multi_process): New.
19609	* server.c (handle_query): Even if GDB reports support, only
19610	enable multi-process if the target also supports it.  Report
19611	multi-process support only if the target backend supports it.
19612	* linux-low.c (linux_supports_multi_process): New function.
19613	(linux_target_ops): Install it as target_supports_multi_process
19614	callback.
19615
196162009-05-24  Doug Evans  <dje@google.com>
19617
19618	Global renaming of find_thread_pid to find_thread_ptid.
19619	* server.h (find_thread_ptid): Renamed from find_thread_pid.
19620	* inferiors.c (find_thread_ptid): Renamed from find_thread_pid.
19621	All callers updated.
19622
19623	* linux-low.c (handle_extended_wait): Use linux_resume_one_lwp
19624	to resume the newly created thread, don't call ptrace (PTRACE_CONT)
19625	directly.
19626
19627	* linux-low.c (get_stop_pc): Print pc if debug_threads.
19628	(check_removed_breakpoint, linux_wait_for_lwp): Ditto.
19629	(linux_resume_one_lwp): Ditto.
19630
196312009-05-23  Doug Evans  <dje@google.com>
19632
19633	* linux-low.c (linux_resume_one_lwp): Change type of first arg
19634	from struct inferior_list_entry * to struct lwp_info *.
19635	All callers updated.
19636
196372009-05-13  Doug Evans  <dje@google.com>
19638
19639	* linux-x86-low.c: Don't include assert.h.
19640	(x86_siginfo_fixup): Use fatal, not assert.
19641	(x86_arch_setup): Fix comment.
19642
196432009-05-12  Doug Evans  <dje@google.com>
19644
19645	Biarch support for i386/amd64 gdbserver.
19646	* Makefile.in (SFILES): Remove linux-i386-low.c, linux-x86-64-low.c.
19647	Add linux-x86-low.c.
19648	(linux-i386-low.o, linux-x86-64-low.o): Delete.
19649	(linux-x86-low.o): Add.
19650	* linux-x86-64-low.c: Delete.
19651	* linux-i386-low.c: Delete.
19652	* linux-x86-low.c: New file.
19653	* configure.srv (i?86-linux srv_tgtobj): Replace linux-i386-low.o with
19654	linux-x86-low.o.
19655	(x86_64-linux srv_tgtobj): Replace linux-x86-64-low.o with
19656	linux-x86-low.o.
19657	(x86_64-linux srv_regobj): Add reg-i386-linux.o.
19658	* linux-low.c: Include ansidecl.h, elf/common.h, elf/external.h.
19659	(linux_child_pid_to_exec_file): New function.
19660	(elf_64_header_p, elf_64_file_p): New functions.
19661	(siginfo_fixup): New function.
19662	(linux_xfer_siginfo): New local inf_siginfo.  Call siginfo_fixup to
19663	give target a chance to convert layout.
19664	* linux-low.h (linux_target_ops): New member siginfo_fixup.
19665	(linux_child_pid_to_exec_file, elf_64_file_p): Declare.
19666
196672009-05-07  Doug Evans  <dje@google.com>
19668
19669	* linux-low.c (regsets_fetch_inferior_registers): Fix memory leak.
19670	(regsets_store_inferior_registers): Ditto.
19671
196722009-05-06  Pedro Alves  <pedro@codesourcery.com>
19673
19674	PR server/10048
19675
19676	* linux-low.c (must_set_ptrace_flags): Delete.
19677	(linux_create_inferior): Set `lwp->must_set_ptrace_flags' instead
19678	of the global.
19679	(linux_attach_lwp_1): Don't set PTRACE_SETOPTIONS here.  Set
19680	`lwp->must_set_ptrace_flags' instead.
19681	(linux_wait_for_event_1): Set ptrace options here.
19682	(linux_wait_1): ... not here.
19683
196842009-04-30  Doug Evans  <dje@google.com>
19685
19686	* inferiors.c (started_inferior_callback): New function.
19687	(attached_inferior_callback): New function.
19688	(have_started_inferiors_p, have_attached_inferiors_p): New functions.
19689	* server.c (print_started_pid, print_attached_pid): New functions.
19690	(detach_or_kill_for_exit): New function.
19691	(main): Call it instead of for_each_inferior (kill_inferior_callback).
19692	* server.h (have_started_inferiors_p): Declare.
19693	(have_attached_inferiors_p): Declare.
19694
19695	* inferiors.c (remove_process): Fix memory leak, free process.
19696	* linux-low.c (linux_remove_process): New function.
19697	(linux_kill): Call it instead of remove_process.
19698	(linux_detach, linux_wait_1): Ditto.
19699
197002009-04-19  Danny Backx  <dannybackx@users.sourceforge.net>
19701
19702	* configure.srv: Add x86 Windows CE target.
19703
197042009-04-03  Ulrich Weigand  <uweigand@de.ibm.com>
19705
19706	* inferiors.c (get_thread_process): Make global.
19707	* server.h (get_thread_process): Add prototype.
19708	* thread-db.c (find_one_thread): Use get_thread_process
19709	instead of current_process.
19710	(thread_db_get_tls_address): Do not crash if called when
19711	thread layer is not yet initialized.
19712
197132009-04-03  Ulrich Weigand  <uweigand@de.ibm.com>
19714
19715	* remote-utils.c (prepare_resume_reply): Null-terminate packet.
19716	* spu-low.c (current_tid): Rename to ...
19717	(current_ptid): ... this.
19718	(fetch_ppc_register, fetch_ppc_memory, store_ppc_memory,
19719	spu_proc_xfer_spu, spu_resume, spu_request_interrupt): Use
19720	ptid_get_lwp (current_ptid) instead of current_tid.
19721	(spu_kill, spu_detach, spu_join, spu_wait): Use pid argument
19722	instead of current_tid.  Use find_process_pid to verify pid
19723	argument is valid.  Pass proper argument to remove_process.
19724	(spu_thread_alive): Compare current_ptid instead of current_tid.
19725	(spu_resume): Likewise.
19726
197272009-04-02  Pedro Alves  <pedro@codesourcery.com>
19728
19729	* linux-low.c (usr_store_inferior_registers): Declare local `pid'
19730	variable.
19731
197322009-04-01  Pedro Alves  <pedro@codesourcery.com>
19733
19734	Implement the multiprocess extensions, and add linux multiprocess
19735	support.
19736
19737	* server.h (ULONGEST): Declare.
19738	(struct ptid, ptid_t): New.
19739	(minus_one_ptid, null_ptid): Declare.
19740	(ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
19741	(ptid_get_tid, ptid_equal, ptid_is_pid): Declare.
19742	(struct inferior_list_entry): Change `id' type from unsigned from
19743	to ptid_t.
19744	(struct sym_cache, struct breakpoint, struct
19745	process_info_private): Forward declare.
19746	(struct process_info): Declare.
19747	(current_process): Declare.
19748	(all_processes): Declare.
19749	(initialize_inferiors): Declare.
19750	(add_thread): Adjust to use ptid_t.
19751	(thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): Ditto.
19752	(add_process, remove_process, find_thread_pid): Declare.
19753	(find_inferior_id): Adjust to use ptid_t.
19754	(cont_thread, general_thread, step_thread): Change type to ptid_t.
19755	(multi_process): Declare.
19756	(push_event): Adjust to use ptid_t.
19757	(read_ptid, write_ptid): Declare.
19758	(prepare_resume_reply): Adjust to use ptid_t.
19759	(clear_symbol_cache): Declare.
19760	* inferiors.c (all_processes): New.
19761	(null_ptid, minus_one_ptid): New.
19762	(ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
19763	(ptid_get_tid, ptid_equal, ptid_is_pid): New.
19764	(add_thread): Change unsigned long to ptid.  Remove gdb_id
19765	parameter.  Adjust.
19766	(thread_id_to_gdb_id, thread_to_gdb_id): Change unsigned long to ptid.
19767	(gdb_id_to_thread): Rename to ...
19768	(find_thread_pid): ... this.  Change unsigned long to ptid.
19769	(gdb_id_to_thread_id, find_inferior_id): Change unsigned long to ptid.
19770	(loaded_dll, pull_pid_from_list): Adjust.
19771	(add_process, remove_process, find_process_pid)
19772	(get_thread_process, current_process, initialize_inferiors): New.
19773	* target.h (struct thread_resume) <thread>: Change type to ptid_t.
19774	(struct target_waitstatus) <related_pid>: Ditto.
19775	(struct target_ops) <kill, detach>: Add `pid' argument.  Change
19776	return type to int.
19777	(struct target_ops) <join>: Add `pid' argument.
19778	(struct target_ops) <thread_alive>: Change pid's type to ptid_t.
19779	(struct target_ops) <wait>: Add `ptid' field.  Change return type
19780	to ptid.
19781	(kill_inferior, detach_inferior, join_inferior): Add `pid' argument.
19782	(mywait): Add `ptid' argument.  Change return type to ptid_t.
19783	(target_pid_to_str): Declare.
19784	* target.c (set_desired_inferior): Adjust to use ptids.
19785	(mywait): Add new `ptid' argument.  Adjust.
19786	(target_pid_to_str): New.
19787	* mem-break.h (free_all_breakpoints): Declare.
19788	* mem-break.c (breakpoints): Delelete.
19789	(set_breakpoint_at, delete_breakpoint, find_breakpoint_at)
19790	(check_mem_read, check_mem_write, delete_all_breakpoints): Adjust
19791	to use per-process breakpoint list.
19792	(free_all_breakpoints): New.
19793	* remote-utils.c (struct sym_cache) <name>: Drop `const'.
19794	(symbol_cache, all_symbols_looked_up): Delete.
19795	(hexchars): New.
19796	(ishex, unpack_varlen_hex, write_ptid, hex_or_minus_one,
19797	read_ptid): New.
19798	(prepare_resume_reply): Change ptid argument's type from unsigned
19799	long to ptid_t.  Adjust.  Implement W;process and X;process.
19800	(free_sym_cache, clear_symbol_cache): New.
19801	(look_up_one_symbol): Adjust to per-process symbol cache.  *
19802	* server.c (cont_thread, general_thread, step_thread): Change type
19803	to ptid_t.
19804	(attached): Delete.
19805	(multi_process): New.
19806	(last_ptid): Change type to ptid_t.
19807	(struct vstop_notif) <ptid>: Change type to ptid_t.
19808	(queue_stop_reply, push_event): Change `ptid' argument's type to
19809	ptid_t.
19810	(discard_queued_stop_replies): Add `pid' argument.
19811	(start_inferior): Adjust to use ptids.  Adjust to mywait interface
19812	changes.  Don't reference the `attached' global.
19813	(attach_inferior): Adjust to mywait interface changes.
19814	(handle_query): Adjust to use ptids.  Parse GDB's qSupported
19815	features.  Handle and report "multiprocess+".  Handle
19816	"qAttached:PID".
19817	(handle_v_cont): Adjust to use ptids.  Adjust to mywait interface
19818	changes.
19819	(handle_v_kill): New.
19820	(handle_v_stopped): Adjust to use target_pid_to_str.
19821	(handle_v_requests): Allow multiple attaches and runs when
19822	multiprocess extensions are in effect.  Handle "vKill".
19823	(myresume): Adjust to use ptids.
19824	(queue_stop_reply_callback): Add `arg' parameter.  Handle it.
19825	(handle_status): Adjust to discard_queued_stop_replies interface
19826	change.
19827	(first_thread_of, kill_inferior_callback)
19828	(detach_or_kill_inferior_callback, join_inferiors_callback): New.
19829	(main): Call initialize_inferiors.  Adjust to use ptids, killing
19830	and detaching from all inferiors.  Handle multiprocess packet
19831	variants.
19832	* linux-low.h: Include gdb_proc_service.h.
19833	(struct process_info_private): New.
19834	(struct linux_target_ops) <pid_of>: Use ptid_get_pid.
19835	<lwpid_of>: Use ptid_get_lwp.
19836	(get_lwp_thread): Adjust.
19837	(struct lwp_info): Add `dead' member.
19838	(find_lwp_pid): Declare.
19839	* linux-low.c (thread_db_active): Delete.
19840	(new_inferior): Adjust comment.
19841	(inferior_pid): Delete.
19842	(linux_add_process): New.
19843	(handle_extended_wait): Adjust.
19844	(add_lwp): Change unsigned long to ptid.
19845	(linux_create_inferior): Add process to processes table.  Adjust
19846	to use ptids.  Don't set new_inferior here.
19847	(linux_attach_lwp): Rename to ...
19848	(linux_attach_lwp_1): ... this.  Add `initial' argument.  Handle
19849	it.  Adjust to use ptids.
19850	(linux_attach_lwp): New.
19851	(linux_attach): Add process to processes table.  Don't set
19852	new_inferior here.
19853	(struct counter): New.
19854	(second_thread_of_pid_p, last_thread_of_process_p): New.
19855	(linux_kill_one_lwp): Add `args' parameter.  Handle it.  Adjust to
19856	multiple processes.
19857	(linux_kill): Add `pid' argument.  Handle it.  Adjust to multiple
19858	processes.  Remove process from process table.
19859	(linux_detach_one_lwp): Add `args' parameter.  Handle it.  Adjust
19860	to multiple processes.
19861	(any_thread_of): New.
19862	(linux_detach): Add `pid' argument, and handle it.  Remove process
19863	from processes table.
19864	(linux_join): Add `pid' argument.  Handle it.
19865	(linux_thread_alive): Change unsighed long argument to ptid_t.
19866	Consider dead lwps as not being alive.
19867	(status_pending_p): Rename `dummy' argument to `arg'.  Filter out
19868	threads we're not interested in.
19869	(same_lwp, find_lwp_pid): New.
19870	(linux_wait_for_lwp): Change `pid' argument's type from int to
19871	ptid_t.  Adjust.
19872	(linux_wait_for_event): Rename to ...
19873	(linux_wait_for_event_1): ... this.  Change `pid' argument's type
19874	from int to ptid_t.  Adjust.
19875	(linux_wait_for_event): New.
19876	(linux_wait_1): Add `ptid' argument.  Change return type to
19877	ptid_t.  Adjust.  Use last_thread_of_process_p.  Remove processes
19878	that exit from the process table.
19879	(linux_wait): Add `ptid' argument.  Change return type to ptid_t.
19880	Adjust.
19881	(mark_lwp_dead): New.
19882	(wait_for_sigstop): Adjust to use ptids.  If a process exits while
19883	stopping all threads, mark its main lwp as dead.
19884	(linux_set_resume_request, linux_resume_one_thread): Adjust to use
19885	ptids.
19886	(fetch_register, usr_store_inferior_registers)
19887	(regsets_fetch_inferior_registers)
19888	(regsets_store_inferior_registers, linux_read_memory)
19889	(linux_write_memory): Inline `inferior_pid'.
19890	(linux_look_up_symbols): Adjust to use per-process
19891	`thread_db_active'.
19892	(linux_request_interrupt): Adjust to use ptids.
19893	(linux_read_auxv): Inline `inferior_pid'.
19894	(initialize_low): Don't reference thread_db_active.
19895	* gdb_proc_service.h (struct ps_prochandle) <pid>: Remove.
19896	* proc-service.c (ps_lgetregs): Use find_lwp_pid.
19897	(ps_getpid): Return the pid of the current inferior.
19898	* thread-db.c (proc_handle, thread_agent): Delete.
19899	(thread_db_create_event, thread_db_enable_reporting): Adjust to
19900	per-process data.
19901	(find_one_thread): Change argument type to ptid_t.  Adjust to
19902	per-process data.
19903	(maybe_attach_thread): Adjust to per-process data and ptids.
19904	(thread_db_find_new_threads): Ditto.
19905	(thread_db_init): Ditto.
19906	* spu-low.c (spu_create_inferior, spu_attach): Add process to
19907	processes table.  Adjust to use ptids.
19908	(spu_kill, spu_detach): Adjust interface.  Remove process from
19909	processes table.
19910	(spu_join, spu_thread_alive): Adjust interface.
19911	(spu_wait): Adjust interface.  Remove process from processes
19912	table.  Adjust to use ptids.
19913	* win32-low.c (current_inferior_tid): Delete.
19914	(current_inferior_ptid): New.
19915	(debug_event_ptid): New.
19916	(thread_rec): Take a ptid.  Adjust.
19917	(child_add_thread): Add `pid' argument.  Adjust to use ptids.
19918	(child_delete_thread): Ditto.
19919	(do_initial_child_stuff): Add `attached' argument.  Add process to
19920	processes table.
19921	(child_fetch_inferior_registers, child_store_inferior_registers):
19922	Adjust.
19923	(win32_create_inferior): Pass 0 to do_initial_child_stuff.
19924	(win32_attach): Pass 1 to do_initial_child_stuff.
19925	(win32_kill): Adjust interface.  Remove process from processes
19926	table.
19927	(win32_detach): Ditto.
19928	(win32_join): Adjust interface.
19929	(win32_thread_alive): Take a ptid.
19930	(win32_resume): Adjust to use ptids.
19931	(get_child_debug_event): Ditto.
19932	(win32_wait): Adjust interface.  Remove exiting process from
19933	processes table.
19934
199352009-04-01  Pedro Alves  <pedro@codesourcery.com>
19936
19937	Non-stop mode support.
19938
19939	* server.h (non_stop): Declare.
19940	(gdb_client_data, handler_func): Declare.
19941	(delete_file_handler, add_file_handler, start_event_loop):
19942	Declare.
19943	(handle_serial_event, handle_target_event, push_event)
19944	(putpkt_notif): Declare.
19945	* target.h (enum resume_kind): New.
19946	(struct thread_resume): Replace `step' field by `kind' field.
19947	(TARGET_WNOHANG): Define.
19948	(struct target_ops) <wait>: Add `options' argument.
19949	<supports_non_stop, async, start_non_stop>: New fields.
19950	(target_supports_non_stop, target_async): New.
19951	(start_non_stop): Declare.
19952	(mywait): Add `options' argument.
19953	* target.c (mywait): Add `options' argument.  Print child exit
19954	notifications here.
19955	(start_non_stop): New.
19956	* server.c (non_stop, own_buf, mem_buf): New globals.
19957	(struct vstop_notif): New.
19958	(notif_queue): New global.
19959	(queue_stop_reply, push_event, discard_queued_stop_replies)
19960	(send_next_stop_reply): New.
19961	(start_inferior): Adjust to use resume_kind.  Adjust to mywait
19962	interface changes.
19963	(attach_inferior): In non-stop mode, don't wait for the target
19964	here.
19965	(handle_general_set): Handle QNonStop.
19966	(handle_query): When handling qC, return the current general
19967	thread, instead of the first thread of the list.
19968	(handle_query): If the backend supports non-stop mode, include
19969	QNonStop+ in the qSupported query response.
19970	(handle_v_cont): Adjust to use resume_kind.  Handle resume_stop
19971	and non-stop mode.
19972	(handle_v_attach, handle_v_run): Handle non-stop mode.
19973	(handle_v_stopped): New.
19974	(handle_v_requests): Report support for vCont;t.  Handle vStopped.
19975	(myresume): Adjust to use resume_kind.  Handle non-stop.
19976	(queue_stop_reply_callback): New.
19977	(handle_status): Handle non-stop mode.
19978	(main): Clear non_stop flag on reconnection.  Use the event-loop.
19979	Refactor serial protocol handling from here ...
19980	(process_serial_event): ... to this new function.  When GDB
19981	selects any thread, select one here.  In non-stop mode, wait until
19982	GDB acks all pending events before exiting.
19983	(handle_serial_event, handle_target_event): New.
19984	* remote-utils.c (remote_open): Install remote_desc in the event
19985	loop.
19986	(remote_close): Remove remote_desc from the event loop.
19987	(putpkt_binary): Rename to...
19988	(putpkt_binary_1): ... this.  Add `is_notic' argument.  Handle it.
19989	(putpkt_binary): New as wrapper around putpkt_binary_1.
19990	(putpkt_notif): New.
19991	(prepare_resume_reply): In non-stop mode, don't change the
19992	general_thread.
19993	* event-loop.c: New.
19994	* Makefile.in (OBJ): Add event-loop.o.
19995	(event-loop.o): New rule.
19996
19997	* linux-low.h (pid_of): Moved here.
19998	(lwpid_of): New.
19999	(get_lwp_thread): Use lwpid_of.
20000	(struct lwp_info): Delete `lwpid' field.  Add `suspended' field.
20001	* linux-low.c (pid_of): Delete.
20002	(inferior_pid): Use lwpid_of.
20003	(linux_event_pipe): New.
20004	(target_is_async_p): New.
20005	(delete_lwp): New.
20006	(handle_extended_wait): Use lwpid_of.
20007	(add_lwp): Don't set lwpid field.
20008	(linux_attach_lwp): Adjust debug output.  Use lwpid_of.
20009	(linux_kill_one_lwp): If killing a running lwp, stop it first.
20010	Use lwpid_of.  Adjust to linux_wait_for_event interface changes.
20011	(linux_detach_one_lwp): If detaching from a running lwp, stop it
20012	first.  Adjust to linux_wait_for_event interface changes.  Use
20013	lwpid_of.
20014	(linux_detach): Don't delete the main lwp here.
20015	(linux_join): Use my_waitpid.  Avoid signal_pid.  Use lwpid_of.
20016	(status_pending_p): Don't consider explicitly suspended lwps.
20017	(linux_wait_for_lwp): Take an integer pid instead of a lwp_info
20018	pointer.  Add OPTIONS argument.  Change return type to int.  Use
20019	my_waitpid instead of sleeping.  Handle WNOHANG.  Use lwpid_of.
20020	(linux_wait_for_event): Take an integer pid instead of a lwp_info
20021	pointer.  Add status pointer argument.  Return a pid instead of a
20022	status.  Use lwpid_of.  Adjust to linux_wait_for_lwp interface
20023	changes.  In non-stop mode, don't switch to a random thread.
20024	(linux_wait): Rename to...
20025	(linux_wait_1): ... this.  Add target_options argument, and handle
20026	it.  Adjust to use resume_kind.  Use lwpid_of.  In non-stop mode,
20027	don't handle the continue thread.  Handle TARGET_WNOHANG.  Merge
20028	clean exit and signal exit code.  Don't stop all threads in
20029	non-stop mode.  In all-stop mode, only stop all threads when
20030	reporting a stop to GDB.  Handle explicit thread stop requests.
20031	(async_file_flush, async_file_mark): New.
20032	(linux_wait): New.
20033	(send_sigstop): Use lwpid_of.
20034	(wait_for_sigstop): Use lwpid_of.  Adjust to linux_wait_for_event
20035	interface changes.  In non-stop mode, don't switch to a random
20036	thread.
20037	(linux_resume_one_lwp): Use lwpid_of.
20038	(linux_continue_one_thread, linux_queue_one_thread): Merge into ...
20039	(linux_resume_one_thread): ... this.  Handle resume_stop.  In
20040	non-stop mode, don't look for pending flag in all threads.
20041	(resume_status_pending_p): Don't consider explicitly suspended
20042	threads.
20043	(my_waitpid): Reimplement.  Emulate __WALL.
20044	(linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
20045	Use lwpid_of.
20046	(sigchld_handler, linux_supports_non_stop, linux_async)
20047	(linux_start_non_stop): New.
20048	(linux_target_ops): Register linux_supports_non_stop, linux_async
20049	and linux_start_non_stop.
20050	(initialize_low): Install SIGCHLD handler.
20051	* thread-db.c (thread_db_create_event, find_one_thread)
20052	(thread_db_get_tls_address): Use lwpid_of.
20053	* win32-low.c (win32_detach): Adjust to use resume_kind.
20054	(win32_wait): Add `options' argument.
20055	* spu-low.c (spu_resume): Adjust to use resume_kind.
20056	(spu_wait): Add `options' argument.
20057
200582009-04-01  Pedro Alves  <pedro@codesourcery.com>
20059
20060	Decouple target code from remote protocol.
20061
20062	* target.h (enum target_waitkind): New.
20063	(struct target_waitstatus): New.
20064	(struct target_ops) <wait>: Return an unsigned long.  Take a
20065	target_waitstatus pointer instead of a char pointer.
20066	(mywait): Likewise.
20067	* target.c (mywait): Change prototype to return an unsigned long.
20068	Take a target_waitstatus pointer instead of a char pointer.  Adjust.
20069	* server.h (thread_from_wait, old_thread_from_wait): Delete
20070	declarations.
20071	(prepare_resume_reply): Change prototype to take a
20072	target_waitstatus.
20073	* server.c (thread_from_wait, old_thread_from_wait): Delete.
20074	(last_status, last_ptid): New.
20075	(start_inferior): Remove "statusptr" argument.  Adjust.  Return a
20076	pid instead of a signal.
20077	(attach_inferior): Remove "status" and "signal" parameters.
20078	Adjust.
20079	(handle_query): For qGetTLSAddr, parse the thread id with strtol,
20080	not as an address.
20081	(handle_v_cont, handle_v_attach, handle_v_run, handle_v_kill)
20082	(handle_v_requests, myresume): Remove "status" and "signal"
20083	parameters.  Adjust.
20084	(handle_status): New.
20085	(main): Delete local `status'.  Adjust.
20086	* remote-utils.c: Include target.h.
20087	(prepare_resume_reply): Change prototype to take a
20088	target_waitstatus.  Adjust.
20089
20090	* linux-low.c (linux_wait): Adjust to new target_ops->wait
20091	interface.
20092	* spu-low.c (spu_wait): Adjust.
20093	* win32-low.c (enum target_waitkind, struct target_waitstatus):
20094	Delete.
20095	(win32_wait): Adjust.
20096
200972009-04-01  Pedro Alves  <pedro@codesourcery.com>
20098
20099	* target.h (struct thread_resume): Delete leave_stopped member.
20100	(struct target_ops): Add a `n' argument to the `resume' callback.
20101	* server.c (start_inferior): Adjust.
20102	(handle_v_cont, myresume): Adjust.
20103	* linux-low.c (check_removed_breakpoint): Adjust to resume
20104	interface change, and to removed leave_stopped field.
20105	(resume_ptr): Delete.
20106	(struct thread_resume_array): New.
20107	(linux_set_resume_request): Add new `arg' parameter.  Adjust to
20108	resume interface change.
20109	(linux_continue_one_thread, linux_queue_one_thread)
20110	(resume_status_pending_p): Check if the resume field is NULL
20111	instead of checking the leave_stopped member.
20112	(linux_resume): Adjust to the target resume interface change.
20113	* spu-low.c (spu_resume): Adjust to the target resume interface
20114	change.
20115	* win32-low.c (win32_detach, win32_resume): Ditto.
20116
201172009-04-01  Pedro Alves  <pedro@codesourcery.com>
20118
20119	* linux-low.c (linux_wait_for_event): Don't clear the `stepping'
20120	flag.
20121	(wait_for_sigstop): Don't leave a finished single-step SIGTRAP
20122	pending.
20123	(linux_continue_one_thread): Only preserve the stepping flag if
20124	there's a pending breakpoint.
20125
201262009-03-31  Pedro Alves  <pedro@codesourcery.com>
20127
20128	* server.c (main): After the inferior having exited, call
20129	remote_close before exiting gdbserver.
20130
201312009-03-25  Thiago Jung Bauermann  <bauerman@br.ibm.com>
20132
20133	Fix size of FPSCR in Power 7 processors.
20134	* linux-ppc-low.c (PPC_FEATURE_ARCH_2_05): Remove #define.
20135	(PPC_FEATURE_HAS_DFP): New #define.
20136	(ppc_arch_setup): Check for DFP feature instead of ISA 2.05 to decide on
20137	size of the FPSCR.
20138
201392009-03-23  Pedro Alves  <pedro@codesourcery.com>
20140
20141	* server.c (handle_query) Whitespace and formatting.
20142
201432009-03-22  Pedro Alves  <pedro@codesourcery.com>
20144
20145	* i387-fp.c, linux-arm-low.c, linux-cris-low.c,
20146	linux-crisv32-low.c, linux-i386-low.c, linux-low.c,
20147	linux-mips-low.c, linux-s390-low.c, linux-sparc-low.c,
20148	linux-x86-64-low.c, linux-xtensa-low.c, proc-service.c,
20149	regcache.c, remote-utils.c, server.c, spu-low.c, target.h,
20150	thread-db.c, win32-low.c, xtensa-xtregs.c, gdbreplay.c,
20151	Makefile.in, configure.ac: Fix whitespace throughout.
20152	* configure: Regenerate.
20153
201542009-03-22  Pedro Alves  <pedro@codesourcery.com>
20155
20156	* inferiors.c (find_inferior): Make it safe for the callback
20157	function to delete the currently iterated inferior.
20158
201592009-03-22  Pedro Alves  <pedro@codesourcery.com>
20160
20161	* Makefile.in (linuw_low_h): Move higher.
20162	(thread-db.o): Depend on $(linux_low_h).
20163
201642009-03-17  Pedro Alves  <pedro@codesourcery.com>
20165
20166	Rename "process" to "lwp" throughout.
20167
20168	* linux-low.c (all_processes): Rename to...
20169	(all_lwps): ... this.
20170	(inferior_pid, handle_extended_wait, get_stop_pc): Adjust.
20171	(add_process): Rename to ...
20172	(add_lwp): ... this.  Adjust.
20173	(linux_create_inferior): Adjust.
20174	(linux_attach_lwp): Adjust.
20175	(linux_attach): Adjust.
20176	(linux_kill_one_process): Rename to ...
20177	(linux_kill_one_lwp): ... this.  Adjust.
20178	(linux_kill): Adjust.
20179	(linux_detach_one_process): Rename to ...
20180	(linux_detach_one_lwp): ... this.  Adjust.
20181	(linux_detach): Adjust.
20182	(check_removed_breakpoint): Adjust.
20183	(status_pending_p): Adjust.
20184	(linux_wait_for_process): Rename to ...
20185	(linux_wait_for_lwp): ... this.  Adjust.
20186	(linux_wait_for_event): Adjust.
20187	(send_sigstop): Adjust.
20188	(wait_for_sigstop): Adjust.
20189	(stop_all_processes): Rename to ...
20190	(stop_all_lwps): ... this.
20191	(linux_resume_one_process): Rename to ...
20192	(linux_resume_one_lwp): ... this.  Adjust.
20193	(linux_set_resume_request, linux_continue_one_thread)
20194	(linux_queue_one_thread, resume_status_pending_p)
20195	(usr_store_inferior_registers, regsets_store_inferior_registers)
20196	(linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
20197	Adjust.
20198	* linux-low.h (get_process): Rename to ...
20199	(get_lwp): ... this.  Adjust.
20200	(get_thread_process): Rename to ...
20201	(get_thread_lwp): ... this.  Adjust.
20202	(get_process_thread): Rename to ...
20203	(get_lwp_thread): ... this.  Adjust.
20204	(struct process_info): Rename to ...
20205	(struct lwp_info): ... this.
20206	(all_processes): Rename to ...
20207	(all_lwps): ... this.
20208	* proc-service.c (ps_lgetregs): Adjust.
20209	* thread-db.c (thread_db_create_event, find_one_thread)
20210	(maybe_attach_thread, thread_db_get_tls_address): Adjust.
20211
202122009-03-14  Pedro Alves  <pedro@codesourcery.com>
20213
20214	* server.c (handle_query): Handle "qAttached".
20215
202162009-03-13  Nathan Sidwell  <nathan@codesourcery.com>
20217
20218	* Makefile.in, hostio-errno.c, errno.c, xtensa-xtregs.c: Change to
20219	GPLv3, update license URL.
20220
202212009-03-01  Doug Evans  <dje@google.com>
20222
20223	* Makefile.in (INCLUDE_CFLAGS): Add -I$(srcdir)/../common.
20224	(server_h): Add gdb_signals.h.
20225	(signals.o): Update.
20226	* server.h (target_signal_from_host,target_signal_to_host_p)
20227	(target_signal_to_host,target_signal_to_name): Moved to gdb_signals.h.
20228
202292009-02-14  Pierre Muller  <muller@ics.u-strasbg.fr>
20230
20231	* remote-utils.c (getpkt): Also generate remote-debug
20232	information if noack_mode is set.
20233
202342009-02-06  Pedro Alves  <pedro@codesourcery.com>
20235
20236	* server.c (handle_query): Report qXfer:siginfo:read and
20237	qXfer:siginfo:write as supported and handle them.
20238	* target.h (struct target_ops) <qxfer_siginfo>: New field.
20239	* linux-low.c (linux_xfer_siginfo): New.
20240	(linux_target_ops): Set it.
20241
202422009-01-26  Pedro Alves  <pedro@codesourcery.com>
20243
20244	* server.c (gdbserver_usage): Mention --remote-debug.
20245	(main): Accept '--remote-debug' switch.
20246
202472009-01-18  Doug Evans  <dje@google.com>
20248
20249	* regcache.c (new_register_cache): No need to check result of xcalloc.
20250	* server.c (handle_search_memory): Back out calls to xmalloc,
20251	result is checked and error is returned to user upon failure.
20252	(handle_query): Ditto.  Add more checks for result of malloc.
20253	(handle_v_cont): Check result of malloc, report error back to
20254	user upon failure.
20255	(handle_v_run): Ditto.  Call freeargv.
20256	* server.h (freeargv): Declare.
20257	* utils.c (freeargv): New fn.
20258
202592009-01-15  Doug Evans  <dje@google.com>
20260
20261	* gdbreplay.c (perror_with_name): Make arg const char *.
20262	* server.h (target_signal_to_name): Make return type const char *.
20263	* thread-db.c (thread_db_err_str): Make return type const char *.
20264	* utils.c (perror_with_name): Make arg const char *.
20265
202662009-01-14  Pedro Alves  <pedro@codesourcery.com>
20267
20268	* win32-low.c (get_child_debug_event): Issue a final DBG_CONTINUE
20269	when handling a EXIT_PROCESS_DEBUG_EVENT.
20270
202712009-01-06  Joel Brobecker  <brobecker@adacore.com>
20272
20273	* gdbreplay.c (gdbreplay_version): Update copyright year.
20274	* server.c (gdbserver_version): Likewise.
20275
202762009-01-05  Doug Evans  <dje@google.com>
20277
20278	* linux-low.c (linux_attach_lwp): Add some comments/fixmes.
20279	(handle_extended_wait): Improve comment.
20280
202812008-12-13  Doug Evans  <dje@google.com>
20282
20283	* utils.c (xmalloc,xcalloc,xstrdup): New fns.
20284	* server.h (ATTR_MALLOC): New macro.
20285	(xmalloc,xcalloc,xstrdup): Declare.
20286	* hostio.c: Replace malloc,calloc,strdup with xmalloc,xcalloc,xstrdup.
20287	* inferiors.c: Ditto.
20288	* linux-low.c: Ditto.
20289	* mem-break.c: Ditto.
20290	* regcache.c: Ditto.
20291	* remote-utils.c: Ditto.
20292	* server.c: Ditto.
20293	* target.c: Ditto.
20294	* win32-low.c: Ditto.
20295
202962008-12-12  Doug Evans  <dje@google.com>
20297
20298	* linux-low.c (linux_wait_for_process): Don't clobber current_inferior
20299	in debugging printf.
20300
20301	* linux-low.c (handle_extended_wait): Simplify, use my_waitpid.
20302
203032008-12-09  Doug Evans  <dje@google.com>
20304
20305	* linux-low.h (struct process_info): Delete member tid, unused.
20306	* thread-db.c (find_one_thread): Update.
20307	(maybe_attach_thread): Update.
20308
203092008-12-02  Pedro Alves  <pedro@codesourcery.com>
20310
20311	* target.h (struct target_ops): Add qxfer_osdata member.
20312	* linux-low.c: Include ctype.h and pwd.h and sys/types.h
20313	and dirent.h.
20314	(linux_qxfer_osdata): New functions.
20315	(linux_target_ops): Register linux_qxfer_osdata as qxfer_osdata
20316	callback.
20317	* server.c (handle_query): Handle "qXfer:osdata:read:".
20318	* remote-utils.c (buffer_grow, buffer_free, buffer_init, buffer_finish)
20319	(buffer_xml_printf): New functions.
20320	* server.h (struct buffer): New.
20321	(buffer_grow_str, buffer_grow_str0): New macros.
20322	(buffer_grow, buffer_free, buffer_init, buffer_finish)
20323	(buffer_xml_printf): Declare.
20324
203252008-11-24  Doug Evans  <dje@google.com>
20326
20327	* Makefile.in (VERSION,DIST,LINT,LINTFLAGS): Delete, unused.
20328
203292008-11-24  Daniel Jacobowitz  <dan@codesourcery.com>
20330
20331	* server.c (handle_v_run): Always use the supplied argument list.
20332
203332008-11-19  Bob Wilson  <bob.wilson@acm.org>
20334
20335	* xtensa-xtregs.c (XTENSA_ELF_XTREG_SIZE): Change to 4.
20336	(xtensa_regmap_table): Add entry for scompare1.
20337
203382008-11-18  Thiago Jung Bauermann  <bauerman@br.ibm.com>
20339
20340	* Makefile.in (powerpc-isa205-32l.o, powerpc-isa205-32l.c,
20341	powerpc-isa205-altivec32l.o, powerpc-isa205-altivec32l.c,
20342	powerpc-isa205-vsx32l.o, powerpc-isa205-vsx32l.c,
20343	powerpc-isa205-64l.o, powerpc-isa205-64l.c,
20344	powerpc-isa205-altivec64l.o, powerpc-isa205-altivec64l.c,
20345	powerpc-isa205-vsx64l.o, powerpc-isa205-vsx64l.c): New targets.
20346	* configure.srv (powerpc*-*-linux*): Add ISA 2.05 object files and
20347	XML target descriptions.
20348	* linux-ppc-low.c (ppc_arch_setup): Init registers with 64-bit FPSCR
20349	when inferior is running on an ISA 2.05 or later processor.  Add
20350	special case to return offset for full 64-bit slot of FPSCR when
20351	in 32-bits.
20352
203532008-11-14  Daniel Gutson  <dgutson@codesourcery.com>
20354
20355	* Makefile.in (SFILES, clean): Added sparc64 files.
20356	(reg-sparc64.o, reg-sparc64.c): New.
20357	* configure.srv (sparc*-*-linux*): New configuration.
20358	* linux-low.c (regsets_fetch_inferior_registers): Swap ptrace
20359	syscall arguments for SPARC.
20360	(regsets_store_inferior_registers): Likewise.
20361	* linux-sparc-low.c: New file.
20362
203632008-10-21  Doug Evans  <dje@google.com>
20364
20365	* Makefile.in (BFD_DIR,BFD,BFD_SRC,BFD_CFLAGS): Delete.
20366	(READLINE_DIR,READLINE_DEP): Delete.
20367	(INTERNAL_CFLAGS): Update.
20368	(LINTFLAGS): Update.
20369
203702008-10-10  Pedro Alves  <pedro@codesourcery.com>
20371
20372	* server.c (handle_v_run): If GDB didn't specify an argv, use the
20373	whole argv from the last run, not just argv[0].
20374
203752008-09-08  Pedro Alves  <pedro@codesourcery.com>
20376
20377	* regcache.c (new_register_cache): Return NULL if the register
20378	cache size isn't known yet.
20379	(free_register_cache): Avoid dereferencing a NULL regcache.
20380
203812008-09-04  Daniel Jacobowitz  <dan@codesourcery.com>
20382
20383	* configure.srv: Merge MIPS and MIPS64.
20384
203852008-08-24  Maciej W. Rozycki  <macro@linux-mips.org>
20386
20387	* Makefile.in (uninstall): Apply $(EXEEXT) too.
20388
203892008-08-18  Luis Machado  <luisgpm@br.ibm.com>
20390
20391	* Makefile.in: Add required vsx dependencies.
20392
20393	* linux-ppc-low: Define PPC_FEATURE_HAS_VSX.
20394	Declare init_registers_powerpc_vsx32l.
20395	Declare init_registers_powerpc_vsx64l.
20396	Define PTRACE_GETVSXREGS and PTRACE_SETVSXREGS.
20397	(ppc_arch_setup): Check for VSX in hwcap.
20398	(ppc_fill_vsxregset): New function.
20399	(ppc_store_vsxregset): New function.
20400	Add new VSX entry in regset_info target_regsets.
20401
20402	* configure.srv: Add new VSX dependencies.
20403
204042008-08-12  Pedro Alves  <pedro@codesourcery.com>
20405
20406	* remote-utils.c (noack_mode, transport_is_reliable): New globals.
20407	(remote_open): Set or clear transport_is_reliable.
20408	(putpkt_binary): Don't expect acks in noack mode.
20409	(getpkt): Don't send ack/nac in noack mode.
20410	* server.c (handle_general_set): Handle QStartNoAckMode.
20411	(handle_query): If connected by tcp pass QStartNoAckMode+ in
20412	qSupported.
20413	(main): Reset noack_mode on every connection.
20414	* server.h (noack_mode): Declare.
20415
204162008-08-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
20417
20418	* Makefile.in (GDBREPLAY_OBS): New variable.
20419	(gdbreplay$(EXEEXT)): Use it to avoid unportable $^.
20420
204212008-08-05  Ulrich Weigand  <uweigand@de.ibm.com>
20422	    Daniel Jacobowitz  <dan@codesourcery.com>
20423
20424	* linux-low.c (linux_resume_one_process): Ignore ESRCH.
20425	(usr_store_inferior_registers): Likewise.
20426	(regsets_store_inferior_registers): Likewise.
20427
204282008-07-31  Rolf Jansen  <rj@surtec.com>
20429	    Pedro Alves  <pedro@codesourcery.com>
20430
20431	* configure.ac: Check for memmem declaration.
20432	* server.c [HAVE_MALLOC_H]: Include malloc.h.
20433	(disable_packet_vCont, disable_packet_Tthread, disable_packet_qC)
20434	(disable_packet_qfThreadInfo): Unconditionally compile.
20435	* server.h [!HAVE_DECL_MEMMEM]: Declare memmem.
20436	* configure, config.in: Regenerate.
20437
204382008-07-28  Doug Kwan  <dougkwan@google.com>
20439
20440	* linux-low.c (sys/dir.h, sys/user.h): Remove includes.
20441	(linux_write_memory): Remove declaration of errno.
20442
204432008-07-12  Ulrich Weigand  <uweigand@de.ibm.com>
20444
20445	* linux-low.c (handle_extended_wait): Do not use "status"
20446	variable uninitialized.
20447
204482008-07-07  Pedro Alves  <pedro@codesourcery.com>
20449
20450	* server.c (handle_v_attach): Inhibit reporting dll changes.
20451
204522008-06-27  Pedro Alves  <pedro@codesourcery.com>
20453
20454	* remote-utils.c (prepare_resume_reply): If requested, don't
20455	output "thread:TID" in the T stop reply.
20456
20457	* server.c (disable_packet_vCont, disable_packet_Tthread)
20458	(disable_packet_qC, disable_packet_qfThreadInfo): New globals.
20459	(handle_query): If requested, disable support for qC, qfThreadInfo
20460	and qsThreadInfo.
20461	(handle_v_requests): If requested, disable support for vCont.
20462	(gdbserver_show_disableable): New.
20463	(main): Handle --disable-packet and --disable-packet=LIST.
20464
20465	* server.h (disable_packet_vCont, disable_packet_Tthread)
20466	(disable_packet_qC, disable_packet_qfThreadInfo): Declare.
20467
204682008-06-20  Carlos O'Donell  <carlos@codesourcery.com>
20469
20470	* server.c (gdbserver_usage): Mention --version.
20471
204722008-06-06  Daniel Jacobowitz  <dan@codesourcery.com>
20473
20474	* Makefile.in (gdbreplay.o): New rule.
20475
204762008-06-06  Joseph Myers  <joseph@codesourcery.com>
20477
20478	* gdbreplay.c (gdbreplay_version): Say gdbreplay in version
20479	message, not gdbserver.
20480
204812008-06-05  Vladimir Prus  <vladimir@codesourcery.com>
20482	    Nathan Sidwell  <nathan@codesourcery.com>
20483	    Joseph Myers  <joseph@codesourcery.com>
20484
20485	* acinclude.m4: Include ../../config/acx.m4.
20486	* configure.ac: Use ACX_PKGVERSION and ACX_BUGURL.
20487	* configure, config.in: Regenerate.
20488	* Makefile.in (gdbreplay$(EXEEXT)): Add version.o.
20489	* server.c (gdbserver_version): Print PKGVERSION.
20490	(gdbsrever_usage): Add stream parameter.  Print REPORT_BUGS_TO.
20491	(main): Adjust gdbserver_usage calls.
20492	* gdbreplay.c (version, host_name): Add declarations.
20493	(gdbreplay_version, gdbreplay_usage): New.
20494	(main): Accept --version and --help options.
20495
204962008-06-04  Daniel Jacobowitz  <dan@codesourcery.com>
20497
20498	* linux-arm-low.c (thumb_breakpoint, thumb_breakpoint_len): New.
20499	(arm_breakpoint_at): Handle Thumb.
20500	(the_low_target): Add comment.
20501
205022008-05-29  Ulrich Weigand  <uweigand@de.ibm.com>
20503
20504	* linux-ppc-low.c (ppc_collect_ptrace_register): Clear buffer.
20505
205062008-05-09  Doug Evans  <dje@google.com>
20507
20508	* server.h (decode_search_memory_packet): Declare.
20509	* remote-utils.c (decode_search_memory_packet): New fn.
20510	* server.c (handle_search_memory_1): New fn.
20511	(handle_search_memory): New fn.
20512	(handle_query): Process qSearch:memory packets.
20513
205142008-05-08  Ulrich Weigand  <uweigand@de.ibm.com>
20515
20516	* regcache.c (registers_length): Remove.
20517	(set_register_cache): Verify that PBUFSIZ is large enough to hold a
20518	full register packet.
20519	* regcache.h (registers_length): Remove prototype.
20520	* server.h (PBUFSIZ): Define to 16384.
20521
205222008-05-03  Ulrich Weigand  <uweigand@de.ibm.com>
20523
20524	* configure.srv (powerpc*-*-linux*): Set srv_regobj to
20525	powerpc-32l.o, powerpc-altivec32l.o, powerpc-e500l.o,
20526	powerpc-64l.o, and powerpc-altivec64l.o.
20527	Remove rs6000/powerpc-32.xml, rs6000/powerpc-64.xml, and
20528	rs6000/powerpc-e500.xml; add rs6000/powerpc-32l.xml,
20529	rs6000/powerpc-altivec32l.xml, rs6000/powerpc-e500l.xml,
20530	rs6000/powerpc-64l.xml, rs6000/powerpc-altivec64l.xml,
20531	rs6000/power-linux.xml, and rs6000/power64-linux.xml
20532	to srv_xmlfiles.
20533
20534	* Makefile.in (reg-ppc.o, reg-ppc.c): Remove, replace by ...
20535	(powerpc-32l.o, powerpc-32l.c): ... these new rules.
20536	(powerpc-32.o, powerpc-32.c): Remove, replace by ...
20537	(powerpc-altivec32l.o, powerpc-altivec32l.c): ... these new rules.
20538	(powerpc-e500.o, powerpc-e500.c): Remove, replace by ...
20539	(powerpc-e500l.o, powerpc-e500l.c): ... these new rules.
20540	(reg-ppc64.o, reg-ppc64.c): Remove, replace by ...
20541	(powerpc-64l.o, powerpc-64l.c): ... these new rules.
20542	(powerpc-64.o, powerpc-64.c): Remove, replace by ...
20543	(powerpc-altivec64l.o, powerpc-altivec64l.c): ... these new rules.
20544	(clean): Update.
20545
20546	* linux-ppc-low.c (init_registers_ppc): Remove, replace by ...
20547	(init_registers_powerpc_32l): ... this new prototype.
20548	(init_registers_powerpc_32): Remove, replace by ...
20549	(init_registers_powerpc_altivec32l): ... this new prototype.
20550	(init_registers_powerpc_e500): Remove, replace by ...
20551	(init_registers_powerpc_e500l): ... this new prototype.
20552	(init_registers_ppc64): Remove, replace by ...
20553	(init_registers_powerpc_64l): ... this new prototype.
20554	(init_registers_powerpc_64): Remove, replace by ...
20555	(init_registers_powerpc_altivec64l): ... this new prototype.
20556	(ppc_num_regs): Set to 73.
20557	(PT_ORIG_R3, PT_TRAP): Define if necessary.
20558	(ppc_regmap, ppc_regmap_e500): Add values for orig_r3 and trap.
20559	(ppc_cannot_store_register): Handle orig_r3 and trap.
20560	(ppc_arch_setup): Update init_registers_... calls.
20561	(ppc_fill_gregset): Handle orig_r3 and trap.
20562
20563	* inferiors.c (clear_inferiors): Reset current_inferior.
20564
205652008-04-23  Paolo Bonzini  <bonzini@gnu.org>
20566
20567	* acinclude.m4: Add override.m4.
20568	* configure: Regenerate.
20569
205702008-04-21  Ulrich Weigand  <uweigand@de.ibm.com>
20571
20572	* linux-ppc-low.c (ppc_arch_setup): Reset ppc_hwcap after the
20573	initial call to init_register_ppc64.
20574
205752008-04-21  Ulrich Weigand  <uweigand@de.ibm.com>
20576
20577	* configure.srv (powerpc64-*-linux*, powerpc-*-linux*): Merge into
20578	single powerpc*-*-linux* case.
20579	(s390-*-linux*, s390x-*-linux*): Merge into single s390*-*-linux* case.
20580
205812008-04-17  Ulrich Weigand  <uweigand@de.ibm.com>
20582
20583	* configure.srv [powerpc64-*-linux*]: Remove powerpc-e500.o from
20584	srv_regobj.  Remove rs6000/powerpc-e500.xml and rs6000/power-spe.xml
20585	from reg_xmlfiles.
20586	* linux-ppc-low.c: Include <elf.h>.
20587	(PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Define.
20588	(ppc_hwcap): New global variable.
20589	(ppc_regmap): Remove __SPE__ #ifdef sections.
20590	(ppc_regmap_e500): New global variable.
20591	(ppc_cannot_store_register): Update __SPE__ special case.
20592	(ppc_get_hwcap): New function.
20593	(ppc_arch_setup): Use it to determine whether inferior supports
20594	AltiVec or SPE registers.  Set the_low_target.regmap if appropriate.
20595	(ppc_fill_vrregset, ppc_store_vrregset): Define unconditionally.
20596	Do not access registers if target does not support AltiVec.
20597	(ppc_fill_evrregset, ppc_store_evrregset): Define unconditionally.
20598	Do not access registers if target does not support SPE.
20599	(target_regsets): Unconditionally include AltiVec and SPE regsets.
20600
206012008-04-17  Daniel Jacobowitz  <dan@codesourcery.com>
20602
20603	* linux-low.c (disabled_regsets, num_regsets): New.
20604	(use_regsets_p): Delete.
20605	(linux_wait_for_process): Clear disabled_regsets.
20606	(regsets_fetch_inferior_registers): Check and set it.
20607	(regsets_store_inferior_registers): Likewise.
20608	(linux_fetch_registers, linux_store_registers): Do not use
20609	use_regsets_p.
20610	(initialize_low): Allocate disabled_regsets.
20611
206122008-04-14  Daniel Jacobowitz  <dan@codesourcery.com>
20613
20614	* Makefile.in (LIBOBJS): New.
20615	(OBS): Use LIBOBJS.
20616	(memmem.o): New rule.
20617	* configure.ac: Use AC_CONFIG_LIBOBJ_DIR and check for memmem.
20618	* configure: Regenerated.
20619
206202008-04-04  Ulrich Weigand  <uweigand@de.ibm.com>
20621
20622	* server.c (handle_query): Never return "unsupported" for
20623	qXfer:features:read queries.
20624
206252008-03-27  Ulrich Weigand  <uweigand@de.ibm.com>
20626
20627	* server.c (get_features_xml): Fix inverted condition.
20628	(handle_query): Always support qXfer:feature:read.
20629
206302008-03-10  Daniel Jacobowitz  <dan@codesourcery.com>
20631
20632	* server.c (wrapper_argv): New.
20633	(start_inferior): Handle wrapper_argv.  If set, expect an extra
20634	trap.
20635	(gdbserver_usage): Document --wrapper.
20636	(main): Parse --wrapper.
20637
206382008-02-28  Ulrich Weigand  <uweigand@de.ibm.com>
20639
20640	* configure.srv [powerpc64-*-linux*]: Add all files mentioned for
20641	powerpc-*-linux* to srv_regobj and reg_xmlfiles.
20642	* linux-ppc-low.c (ppc_get_pc): Support bi-arch operation.
20643	(ppc_set_pc): Likewise.
20644	(ppc_arch_setup): New function.
20645	(ppc_fill_gregset): Call ppc_collect_ptrace_register instead
20646	of collect_register.
20647	(the_low_target): Use ppc_arch_setup as arch_setup initializer.
20648
206492008-02-28  Ulrich Weigand  <uweigand@de.ibm.com>
20650
20651	* configure.srv [powerpc64-*-linux*]: Use linux-ppc-low.o
20652	instead of linux-ppc64-low.o.
20653	* linux-ppc64-low.c: Remove file.
20654	* Makefile.in (SFILES): Remove linux-ppc64-low.c.
20655	(linux-ppc64-low.o): Remove rule.
20656
20657	* linux-ppc-low.c (init_registers_ppc64): Add prototype.
20658	(init_registers_powerpc_64): Likewise.
20659	(ppc_regmap): Conditionally define depending on __powerpc64__.
20660	(ppc_cannot_store_register): Do not special-case "fpscr" when
20661	compiled on __powerpc64__.
20662	(ppc_collect_ptrace_register): New function.
20663	(ppc_supply_ptrace_register): New function.
20664	(ppc_breakpoint): Change type to "unsigned int".
20665	(ppc_breakpoint_at): Change type of "insn" to "unsigned int".
20666	(the_low_target): Conditionally provide initializers for the
20667	arch_setup member depending on __powerpc64__.  Install
20668	collect_ptrace_register and supply_ptrace_register members.
20669
206702008-02-28  Ulrich Weigand  <uweigand@de.ibm.com>
20671
20672	* regcache.h (gdbserver_xmltarget): Add extern declaration.
20673	* server.c (gdbserver_xmltarget): Define.
20674	(get_features_xml): Use it to replace "target.xml" and arch_string.
20675
20676	* configure.srv: Remove srv_xmltarget.  Add XML files that were
20677	mentioned there to srv_xmlfiles instead.  Remove conditional tests
20678	on gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe; set
20679	srv_xmlfiles and srv_regobj to include all possible choices.
20680	* configure.ac (srv_xmltarget): Remove.
20681	(srv_xmlfiles): Do not add "target.xml".
20682	(gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe): Remove
20683	checks for supplementary target information.
20684	* configure: Regenerate.
20685	* Makefile.in (XML_TARGET): Remove.
20686	(target.xml): Remove rule.
20687	(clean): Do not clean up target.xml.
20688	(.PRECIOUS): Do not mention target.xml.
20689
20690	* target.h (struct target_ops): Remove arch_string member.
20691	* linux-low.c (linux_arch_string): Remove.
20692	(linux_target_ops): Remove arch_string initializer.
20693	* linux-low.h (struct linux_target_ops): Remove arch_string member.
20694	* linux-i386-low.c (the_low_target): Remove arch_string initializer.
20695	* linux-x86-64-low.c (the_low_target): Remove arch_string initializer.
20696	* spu-low.c (spu_arch_string): Remove.
20697	(spu_target_ops): Remove arch_string initializer.
20698	* win32-low.c (win32_arch_string): Remove.
20699	(win32_target_ops): Remove arch_string initializer.
20700	* win32-low.h (struct win32_target_ops): Remove arch_string member.
20701	* win32-arm-low.c (the_low_target): Remove arch_string initializer.
20702	* win32-i368-low.c (the_low_target): Remove arch_string initializer.
20703
207042008-02-27  Ulrich Weigand  <uweigand@de.ibm.com>
20705
20706	* linux-low.h (struct linux_target_ops): Replace left_pad_xfer field
20707	by collect_ptrace_register and supply_ptrace_register hooks.
20708	* linux-low.c (fetch_register): Use supply_ptrace_register callback
20709	instead of checking for the_low_target.left_pad_xfer.
20710	(usr_store_inferior_registers): Use collect_ptrace_register callback
20711	instead of checking for the_low_target.left_pad_xfer.
20712
20713	* linux-s390-low.c (s390_collect_ptrace_register): New function.
20714	(s390_supply_ptrace_register): Likewise.
20715	(s390_fill_gregset): Call s390_collect_ptrace_register.
20716	(the_low_target): Update.
20717
20718	* linux-ppc64-low.c (ppc_collect_ptrace_register): New function.
20719	(ppc_supply_ptrace_register): Likewise.
20720	(the_low_target): Update.
20721
20722	* linux-i386-low.c (the_low_target): Update.
20723	* linux-x86-64-low.c (the_low_target): Update.
20724
207252008-02-27  Ulrich Weigand  <uweigand@de.ibm.com>
20726
20727	* configure.srv [s390x-*-linux*]: Set srv_regobj to include both
20728	reg-s390.o and reg-s390x.o.
20729
20730	* linux-low.c (new_inferior): New global variable.
20731	(linux_create_inferior, linux_attach): Set it.
20732	(linux_wait_for_process): Call the_low_target.arch_setup after the
20733	target has stopped for the first time.
20734	(initialize_low): Do not call the_low_target.arch_setup.
20735
20736	* linux-s390-low.c (s390_get_pc): Support bi-arch operation.
20737	(s390_set_pc): Likewise.
20738	(s390_arch_setup): New function.
20739	(the_low_target): Use s390_arch_setup as arch_setup routine.
20740
20741	* regcache.c (realloc_register_cache): New function.
20742	(set_register_cache): Call it for each existing regcache.
20743
207442008-02-27  Ulrich Weigand  <uweigand@de.ibm.com>
20745
20746	* server.h (init_registers): Remove prototype.
20747
20748	* linux-low.h (struct linux_target_ops): Add arch_setup field.
20749	* linux-low.c (initialize_low): Call the_low_target.arch_setup ()
20750	instead of init_registers ().
20751	* linux-arm-low.c (init_registers_arm): Add prototype.
20752	(init_registers_arm_with_iwmmxt): Likewise.
20753	(the_low_target): Add initializer for arch_setup field.
20754	* linux-cris-low.c (init_registers_cris): Add prototype.
20755	(the_low_target): Add initializer for arch_setup field.
20756	* linux-crisv32-low.c (init_registers_crisv32): Add prototype.
20757	(the_low_target): Add initializer for arch_setup field.
20758	* linux-i386-low.c (init_registers_i386_linux): Add prototype.
20759	(the_low_target): Add initializer for arch_setup field.
20760	* linux-ia64-low.c (init_registers_ia64): Add prototype.
20761	(the_low_target): Add initializer for arch_setup field.
20762	* linux-m32r-low.c (init_registers_m32r): Add prototype.
20763	(the_low_target): Add initializer for arch_setup field.
20764	* linux-m68k-low.c (init_registers_m68k): Add prototype.
20765	(the_low_target): Add initializer for arch_setup field.
20766	* linux-mips-low.c (init_registers_mips_linux): Add prototype.
20767	(init_registers_mips64_linux): Likewise.
20768	(the_low_target): Add initializer for arch_setup field.
20769	* linux-ppc-low.c (init_registers_ppc): Add prototype.
20770	(init_registers_powerpc_32, init_registers_powerpc_e500): Likewise.
20771	(the_low_target): Add initializer for arch_setup field.
20772	* linux-ppc64-low.c (init_registers_ppc64): Add prototype.
20773	(init_registers_powerpc_64): Likewise.
20774	(the_low_target): Add initializer for arch_setup field.
20775	* linux-s390-low.c (init_registers_s390): Add prototype.
20776	(init_registers_s390x): Likewise.
20777	(the_low_target): Add initializer for arch_setup field.
20778	* linux-sh-low.c (init_registers_sh): Add prototype.
20779	(the_low_target): Add initializer for arch_setup field.
20780	* linux-x86-64-low.c (init_registers_x86_64_linux): Add prototype.
20781	(the_low_target): Add initializer for arch_setup field.
20782	* linux-xtensa-low.c (init_registers_xtensa): Add prototype.
20783	(the_low_target): Add initializer for arch_setup field.
20784
20785	* win32-low.h (struct win32_target_ops): Add arch_setup field.
20786	* win32-low.c (initialize_low): Call the_low_target.arch_setup ()
20787	instead of init_registers ().
20788	* win32-arm-low.c (init_registers_arm): Add prototype.
20789	(the_low_target): Add initializer for arch_setup field.
20790	* win32-i386-low.c (init_registers_i386): Add prototype.
20791	(the_low_target): Add initializer for arch_setup field.
20792
20793	* spu-low.c (init_registers_spu): Add prototype.
20794	(initialize_low): Call initialie_registers_spu () instead of
20795	initialize_registers ().
20796
207972008-02-19  Pedro Alves  <pedro@codesourcery.com>
20798
20799	* server.c (handle_v_requests): When handling the vRun and vAttach
20800	packets, if already debugging a process, don't kill it.  Return an
20801	error instead.
20802
208032008-02-17  Daniel Jacobowitz  <dan@codesourcery.com>
20804
20805	* server.c (handle_query): Correct length check.
20806
208072008-02-14  Pedro Alves  <pedro_alves@portugalmail.pt>
20808
20809	* win32-low.c (do_initial_child_stuff): Add process handle
20810	parameter.  Set current_process_handle and current_process_id from the
20811	parameters. Clear globals.
20812	(win32_create_inferior): Don't set current_process_handle and
20813	current_process_id here.  Instead pass them on the call to
20814	do_initial_child_stuff.
20815	(win32_attach): Likewise.
20816	(win32_clear_inferiors): New.
20817	(win32_kill): Don't close the current process handle or the
20818	current thread handle here.  Instead call win32_clear_inferiors.
20819	(win32_detach): Don't open a new handle to the process.  Call
20820	win32_clear_inferiors.
20821	(win32_join): Don't rely on current_process_handle; open a new
20822	handle using the process id.
20823	(win32_wait): Call win32_clear_inferiors when the inferior process
20824	has exited.
20825
208262008-02-14  Daniel Jacobowitz  <dan@codesourcery.com>
20827
20828	* server.c (monitor_show_help): Add "exit".
20829
208302008-02-11  Maxim Grigoriev  <maxim2405@gmail.com>
20831
20832	* Makefile.in (SFILES): Add linux-xtensa-low.c.
20833	(clean): Add reg-xtensa.c.
20834	(linux-xtensa-low.o, reg-xtensa.o, reg-xtensa.c): New dependencies.
20835	* configure.srv (xtensa*-*-linux*) New target.
20836	* linux-xtensa-low.c: New.
20837	* xtensa-xtregs.c: New.
20838
208392008-02-01  Pedro Alves  <pedro_alves@portugalmail.pt>
20840
20841	* hostio.c: Don't include errno.h.
20842	(errno_to_fileio_errno): Move to hostio-errno.
20843	* hostio.c: (hostio_error): Remove the error parameter.  Defer the
20844	error number outputting to the target->hostio_last_error callback.
20845	(hostio_packet_error): Use FILEIO_EINVAL directly.
20846	(handle_open, handle_pread, hostio_error, handle_unlink): Update
20847	calls to hostio_error.
20848	* hostio-errno.c: New.
20849	* server.h (hostio_last_error_from_errno): Declare.
20850	* target.h (target_ops): Add hostio_last_error member.
20851	* linux-low.c (linux_target_op): Register hostio_last_error_from_errno
20852	as hostio_last_error handler.
20853	* spu-low.c (spu_target_ops): Likewise.
20854	* win32-low.c [_WIN32_WCE] (win32_error_to_fileio_error)
20855	(wince_hostio_last_error): New functions.
20856	(win32_target_ops) [_WIN32_WCE]: Register wince_hostio_last_error
20857	as hostio_last_error handler.
20858	(win32_target_ops) [!_WIN32_WCE]: Register
20859	hostio_last_error_from_errno as hostio_last_error handler.
20860	* Makefile.in (SFILES): Add hostio.c and hostio-errno.c.
20861	(hostio-errno.o): New rule.
20862	* configure.ac (GDBSERVER_DEPFILES): Add $srv_hostio_err_objs.
20863	* configure.srv (srv_hostio_err_objs): New variable.  Default to
20864	hostio-errno.o.
20865	(arm*-*-mingw32ce*): Set srv_hostio_err_objs to "".
20866	* configure: Regenerate.
20867
208682008-01-29  Daniel Jacobowitz  <dan@codesourcery.com>
20869
20870	* linux-low.c (linux_attach_lwp): Do not _exit after errors.
20871	(linux_kill, linux_detach): Clean up the process list.
20872	* remote-utils.c (remote_open): Improve port number parsing.
20873	(putpkt_binary, input_interrupt): Only send interrupts if the target
20874	is running.
20875	* server.c (extended_protocol): Make static.
20876	(attached): Define earlier.
20877	(exit_requested, response_needed, program_argv): New variables.
20878	(target_running): New.
20879	(start_inferior): Clear attached here.
20880	(attach_inferior): Set attached here.
20881	(require_running): Define.
20882	(handle_query): Use require_running and target_running.  Implement
20883	"monitor exit".
20884	(handle_v_attach, handle_v_run): New.
20885	(handle_v_requests): Use require_running.  Handle vAttach and vRun.
20886	(gdbserver_usage): Update.
20887	(main): Redo argument parsing.  Handle --debug and --multi.  Handle
20888	--attach along with other options or after the port.  Save
20889	program_argv.  Support no initial program.  Resynchronize
20890	communication with GDB after an error.  Handle "monitor exit".
20891	Use require_running and target_running.  Always allow the extended
20892	protocol.  Do not error out for Hc0 or Hc-1.  Do not automatically
20893	restart in extended mode.
20894	* README: Refer to the GDB manual.  Update --attach usage.
20895
208962007-12-20  Andreas Schwab  <schwab@suse.de>
20897
20898	* linux-low.c (STACK_SIZE): Define.
20899	(linux_tracefork_child): Use it.  Use __clone2 on ia64.
20900	(linux_test_for_tracefork): Likewise.
20901
209022007-12-18  Daniel Jacobowitz  <dan@codesourcery.com>
20903
20904	* linux-low.c (linux_wait_for_event): Update messages.  Do not
20905	reinsert auto-delete breakpoints.
20906	* mem-break.c (struct breakpoint): Change return type of handler to
20907	int.
20908	(set_breakpoint_at): Update handler type.
20909	(reinsert_breakpoint_handler): Return 1 instead of calling
20910	delete_breakpoint.
20911	(reinsert_breakpoint_by_bp): Check for the original breakpoint before
20912	setting a new one.
20913	(check_breakpoints): Delete auto-delete breakpoints and return 2.
20914	* mem-break.h (set_breakpoint_at): Update handler type.
20915	* thread-db.c (thread_db_create_event, thread_db_create_event): Update.
20916	* win32-low.c (auto_delete_breakpoint): New.
20917	(get_child_debug_event): Use it.
20918
209192007-12-16  Daniel Jacobowitz  <dan@codesourcery.com>
20920
20921	* configure.ac: Check for pread and pwrite.
20922	* hostio.c (handle_pread): Fall back to lseek and read.
20923	(handle_pwrite): Fall back to lseek and write.
20924	* config.in, configure: Regenerated.
20925
209262007-12-07  Daniel Jacobowitz  <dan@codesourcery.com>
20927
20928	* server.c (myresume): Add own_buf argument.
20929	(main): Update calls.
20930
209312007-12-06  Daniel Jacobowitz  <dan@codesourcery.com>
20932
20933	* linux-low.c (linux_wait, linux_resume): Do not handle async I/O.
20934	* remote-utils.c (remote_open): Do not call disable_async_io.
20935	(block_async_io): Delete.
20936	(unblock_async_io): Make static.
20937	(initialize_async_io): New.
20938	* server.c (handle_v_cont): Handle async I/O here.
20939	(myresume): Likewise.  Move other common resume tasks here...
20940	(main): ... from here.  Call initialize_async_io.  Disable async
20941	I/O before the main loop.
20942	* server.h (initialize_async_io): Declare.
20943	(block_async_io, unblock_async_io): Delete prototypes.
20944	* spu-low.c (spu_resume, spu_wait): Do not handle async I/O here.
20945
209462007-12-06  Mick Davis  <mickd@goanna.iinet.net.au>
20947
20948	* remote-utils.c (readchar): Allow binary data in received messages.
20949
209502007-12-03  Pedro Alves  <pedro_alves@portugalmail.pt>
20951
20952	* win32-low.c (attaching): New global.
20953	(win32_create_inferior): Clear the `attaching' global.
20954	(win32_attach): Set the `attaching' global.
20955	(get_child_debug_event) [_WIN32_WCE]: Stop the inferior when
20956	attaching.  Only set a breakpoint at the entry point if not
20957	attaching.
20958
209592007-12-03  Pedro Alves  <pedro_alves@portugalmail.pt>
20960
20961	* server.c (main): Don't report dll events on the initial
20962	connection on attaches.
20963
209642007-12-03  Pedro Alves  <pedro_alves@portugalmail.pt>
20965
20966	* server.c (main): Relax numerical bases supported for the pid of
20967	the --attach command line argument.
20968
209692007-12-03  Pedro Alves  <pedro_alves@portugalmail.pt>
20970
20971	* win32-low.c (win32_attach): Call OpenProcess before
20972	DebugActiveProcess, not after.  Add last error output to error
20973	call.
20974
209752007-12-03  Pedro Alves  <pedro_alves@portugalmail.pt>
20976
20977	* win32-low.c (win32_get_thread_context)
20978	(win32_set_thread_context): New functions.
20979	(thread_rec): Use win32_get_thread_context.
20980	(continue_one_thread, win32_resume): Use win32_set_thread_context.
20981	* win32-low.h (win32_thread_info) [_WIN32_WCE]: Add `base_context'
20982	field.
20983
209842007-12-03  Leo Zayas
20985	    Pedro Alves  <pedro_alves@portugalmail.pt>
20986
20987	* win32-low.c (soft_interrupt_requested, faked_breakpoint): New
20988	global variables.
20989	(child_add_thread): Minor cleanup.
20990	(child_continue): Resume artificially suspended threads before
20991	calling ContinueDebugEvent.
20992	(suspend_one_thread): New.
20993	(fake_breakpoint_event): New.
20994	(get_child_debug_event): Change return type to int.  Check here if
20995	gdb sent an interrupt request.  If a soft interrupt was requested,
20996	fake a breakpoint event.  Return 0 if there is no event to handle,
20997	and 1 otherwise.
20998	(win32_wait): Don't check here if gdb sent an interrupt request.
20999	Ensure there is a valid event to handle.
21000	(win32_request_interrupt): Add soft interruption method as last
21001	resort.
21002
210032007-12-03  Leo Zayas
21004	    Pedro Alves  <pedro_alves@portugalmail.pt>
21005
21006	* win32-low.h (win32_thread_info): Add descriptions to the
21007	structure members.  Replace `suspend_count' counter by a
21008	`suspended' flag.
21009	* win32-low.c (thread_rec): Update condition of when to get the
21010	context from the inferior.  Rely on ContextFlags being set if it
21011	has already been retrieved.  Only suspend the inferior thread if
21012	we haven't already.  Warn if that fails.
21013	(continue_one_thread): s/suspend_count/suspended/.  Only call
21014	ResumeThread once.  Warn if that fails.
21015
210162007-12-02  Pedro Alves  <pedro_alves@portugalmail.pt>
21017
21018	* win32-low.c (win32_wait): Don't read from the inferior when it
21019	has already exited.
21020
210212007-12-02  Pedro Alves  <pedro_alves@portugalmail.pt>
21022
21023	* Makefile.in (win32_low_h): New variable.
21024	(win32-low.o): Add dependency on $(win32_low_h).
21025	(win32-arm-low.o, win32-i386-low.o): New rules.
21026
210272007-11-30  Daniel Jacobowitz  <dan@codesourcery.com>
21028
21029	* hostio.c: Correct copyright year.
21030
210312007-11-30  Daniel Jacobowitz  <dan@codesourcery.com>
21032
21033	* Makefile.in (OBS): Add hostio.o.
21034	(hostio.o): New rule.
21035	* server.h (handle_vFile): Declare.
21036	* hostio.c: New file.
21037	* server.c (handle_v_requests): Take packet_len and new_packet_len
21038	for binary packets.  Call handle_vFile.
21039	(main): Update call to handle_v_requests.
21040
210412007-11-05  Daniel Jacobowitz  <dan@codesourcery.com>
21042
21043	* linux-low.c: Include <sched.h>.
21044
210452007-11-01  Daniel Jacobowitz  <dan@codesourcery.com>
21046
21047	* linux-low.c (linux_tracefork_grandchild): New.
21048	(linux_tracefork_child): Use clone.
21049	(linux_test_for_tracefork): Use clone; allocate and free a stack.
21050
210512007-10-31  Joel Brobecker  <brobecker@adacore.com>
21052
21053	* Makefile.in: Use $(SHELL) instead of "sh" to call regdat.sh.
21054
210552007-10-24  Daniel Jacobowitz  <dan@codesourcery.com>
21056
21057	* linux-low.c (handle_extended_wait): Handle unexpected signals.
21058
210592007-10-23  Daniel Jacobowitz  <dan@codesourcery.com>
21060
21061	* inferiors.c (change_inferior_id): Delete.
21062	(add_pid_to_list, pull_pid_from_list): New.
21063	* linux-low.c (PTRACE_SETOPTIONS, PTRACE_GETEVENTMSG)
21064	(PTRACE_O_TRACESYSGOOD, PTRACE_O_TRACEFORK, PTRACE_O_TRACEVFORK)
21065	(PTRACE_O_TRACECLONE, PTRACE_O_TRACEEXEC, PTRACE_O_TRACEVFORKDONE)
21066	(PTRACE_O_TRACEEXIT, PTRACE_EVENT_FORK, PTRACE_EVENT_VFORK)
21067	(PTRACE_EVENT_CLONE, PTRACE_EVENT_EXEC, PTRACE_EVENT_VFORK_DONE)
21068	(PTRACE_EVENT_EXIT, __WALL): Provide default definitions.
21069	(stopped_pids, thread_db_active, must_set_ptrace_flags): New variables.
21070	(using_threads): Always set to 1.
21071	(handle_extended_wait): New.
21072	(add_process): Do not set TID.
21073	(linux_create_inferior): Set must_set_ptrace_flags.
21074	(linux_attach_lwp): Remove TID argument.  Do not check using_threads.
21075	Use PTRACE_SETOPTIONS.  Call new_thread_notify.  Update all callers.
21076	(linux_thread_alive): Rename TID argument to LWPID.
21077	(linux_wait_for_process): Handle unknown processes.  Do not use TID.
21078	(linux_wait_for_event): Do not use TID or check using_threads.  Update
21079	call to dead_thread_notify.  Call handle_extended_wait.
21080	(linux_create_inferior): Use PTRACE_SETOPTIONS.
21081	(send_sigstop): Delete sigstop_sent.
21082	(wait_for_sigstop): Avoid TID.
21083	(linux_supports_tracefork_flag, linux_tracefork_child, my_waitpid)
21084	(linux_test_for_tracefork): New.
21085	(linux_lookup_signals): Use thread_db_active and
21086	linux_supports_tracefork_flag.
21087	(initialize_low): Use thread_db_active and linux_test_for_tracefork.
21088	* linux-low.h (get_process_thread): Avoid TID.
21089	(struct process_ifo): Move thread_known and tid to the end.  Remove
21090	sigstop_sent.
21091	(linux_attach_lwp, thread_db_init): Update prototypes.
21092	* server.h (change_inferior_id): Delete prototype.
21093	(add_pid_to_list, pull_pid_from_list): New prototypes.
21094	* thread-db.c (thread_db_use_events): New.
21095	(find_first_thread): Rename to...
21096	(find_one_thread): ...this.  Update callers and messages.  Do not
21097	call fatal.  Check thread_db_use_events.  Do not call
21098	change_inferior_id or new_thread_notify.
21099	(maybe_attach_thread): Update.  Do not call new_thread_notify.
21100	(thread_db_init): Set thread_db_use_events.  Check use_events.
21101	* utils.c (fatal, warning): Correct message prefix.
21102
211032007-10-15  Daniel Jacobowitz  <dan@codesourcery.com>
21104
21105	* Makefile.in (clean): Remove new files.
21106	(powerpc-32.o, powerpc-32.c, powerpc-e500.o, powerpc-e500.c)
21107	(powerpc-64.o, powerpc-64.c): New rules.
21108	* configure.srv: Use alternate register sets for powerpc64-*-linux*
21109	with AltiVec, powerpc-*-linux* with AltiVec, and powerpc-*-linux*
21110	with SPE.
21111	* linux-ppc-low.c (ppc_regmap): Do not fetch the FP registers for
21112	SPE targets.
21113	(ppc_cannot_store_register): Do not check for FPSCR for SPE targets.
21114	(PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS, ppc_fill_vrregset)
21115	(ppc_store_vrregset, PTRACE_GETEVRREGS, PTRACE_SETEVRREGS)
21116	(struct gdb_evrregset_t, ppc_fill_evrregset, ppc_store_evrregset): New.
21117	(target_regsets): Add AltiVec and SPE register sets.
21118	* configure.ac: Check for AltiVec and SPE.
21119	* linux-ppc64-low.c (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS)
21120	(ppc_fill_vrregset, ppc_store_vrregset): New.
21121	(target_regsets): Add AltiVec register set.
21122	* configure: Regenerated.
21123
211242007-09-19  Daniel Jacobowitz  <dan@codesourcery.com>
21125
21126	* linux-low.c (O_LARGEFILE): Define.
21127	(linux_read_memory): Use /proc/PID/mem.
21128	* configure.ac: Use AC_GNU_SOURCE.  Check for pread64.
21129	* configure, config.in: Regenerated.
21130
211312007-09-04  Daniel Jacobowitz  <dan@codesourcery.com>
21132
21133	* linux-low.c (linux_wait_for_event): Do not pass signals while
21134	single-stepping.
21135
211362007-09-03  Pedro Alves  <pedro_alves@portugalmail.pt>
21137
21138	* win32-low.c (create_process): New.
21139	(win32_create_inferior): Use create_process instead of
21140	CreateProcess.  If create_process failed retry appending an ".exe"
21141	suffix.  Store the GetLastError result immediatelly after
21142	create_process calls and use it on the call to error.
21143
211442007-09-03  Pedro Alves  <pedro_alves@portugalmail.pt>
21145
21146	* win32-low.c (handle_load_dll): Don't use toolhelp when waiting.
21147
211482007-08-23  Joel Brobecker  <brobecker@adacore.com>
21149
21150	* configure.ac: Switch license to GPLv3.
21151
211522007-08-01  Michael Snyder  <msnyder@access-company.com>
21153
21154	* remote-utils.c (putpkt_binary): Memory leak, free buf2.
21155
211562007-07-31  Pedro Alves  <pedro_alves@portugalmail.pt>
21157
21158	* win32-low.c (winapi_CloseToolhelp32Snapshot) [_WIN32_WCE]: New
21159	typedef.
21160	(win32_CloseToolhelp32Snapshot) [_WIN32_WCE]: New global var.
21161	(load_toolhelp) [_WIN32_WCE]: Load TOOLHELP.DLL.  Get
21162	CloseToolhelp32Snapshot.
21163	(toolhelp_get_dll_name) [_WIN32_WCE]: Close the snapshot with
21164	CloseToolhelp32Snapshot.
21165
211662007-07-27  Michael Snyder  <michael.snyder@access-company.com>
21167
21168	* server.c (main): Check for inferior exit before main loop.
21169
211702007-07-18  Pedro Alves  <pedro_alves@portugalmail.pt>
21171
21172	* remote-utils.c (remote_open): Set SO_KEEPALIVE on remote_desc
21173	instead of on tmp_desc.
21174
211752007-07-17  Pedro Alves  <pedro_alves@portugalmail.pt>
21176	    Daniel Jacobowitz  <dan@codesourcery.com>
21177
21178	* inferiors.c (all_dlls, dlls_changed, get_dll): New.
21179	(add_thread): Minor cleanups.
21180	(clear_inferiors): Move lower in the file.  Clear the DLL
21181	list.
21182	(free_one_dll, match_dll, loaded_dll, unloaded_dll, clear_list): New.
21183	* remote-utils.c (prepare_resume_reply): Check dlls_changed.
21184	(xml_escape_text): New.
21185	* server.c (handle_query): Handle qXfer:libraries:read.  Report it
21186	for qSupported.
21187	(handle_v_cont): Report errors.
21188	(gdbserver_version): Update.
21189	(main): Correct size of own_buf.  Do not report initial DLL events.
21190	* server.h (struct dll_info, all_dlls, dlls_changed, loaded_dll)
21191	(unloaded_dll, xml_escape_text): New.
21192	* win32-low.c (enum target_waitkind): Update comments.
21193	(win32_add_one_solib, get_image_name, winapi_EnumProcessModules)
21194	(winapi_GetModuleInformation, winapi_GetModuleFileNameExA)
21195	(win32_EnumProcessModules, win32_GetModuleInformation)
21196	(win32_GetModuleFileNameExA, load_psapi, psapi_get_dll_name)
21197	(winapi_CreateToolhelp32Snapshot, winapi_Module32First)
21198	(winapi_Module32Next, win32_CreateToolhelp32Snapshot)
21199	(win32_Module32First, win32_Module32Next, load_toolhelp)
21200	(toolhelp_get_dll_name, handle_load_dll, handle_unload_dll): New.
21201	(get_child_debug_event): Handle DLL events.
21202	(win32_wait): Likewise.
21203
212042007-07-12  Daniel Jacobowitz  <dan@codesourcery.com>
21205
21206	* configure.srv: Set srv_linux_regsets for sh*-*-linux*.
21207	* linux-sh-low.c (sh_fill_gregset, target_regsets): New.
21208
212092007-07-08  Pedro Alves  <pedro_alves@portugalmail.pt>
21210
21211	* win32-low.c (handle_output_debug_string): Ignore event if not
21212	waiting.
21213
212142007-07-08  Pedro Alves  <pedro_alves@portugalmail.pt>
21215
21216	* win32-arm-low.c (arm_wince_breakpoint): Fix typo.
21217
212182007-07-03  Daniel Jacobowitz  <dan@codesourcery.com>
21219
21220	* remote-utils.c (look_up_one_symbol): Handle 'm' packets.
21221
212222007-07-02  Daniel Jacobowitz  <dan@codesourcery.com>
21223
21224	* inferiors.c (change_inferior_id): Add comment.
21225	* linux-low.c (check_removed_breakpoint): Add an early
21226	prototype.  Improve debug output.
21227	(linux_attach): Doc update.
21228	(linux_detach_one_process, linux_detach): Clean up before releasing
21229	each process.
21230	(send_sigstop, wait_for_sigstop): Improve comments and debug output.
21231	* linux-low.h (struct process_info): Doc improvement.
21232	* mem-break.c (delete_all_breakpoints): New.
21233	* mem-break.h (delete_all_breakpoints): New prototype.
21234	* thread-db.c (find_first_thread): New.
21235	(thread_db_create_event): Call it instead of
21236	thread_db_find_new_threads.  Clean up unused variables.
21237	(maybe_attach_thread): Remove first thread handling.
21238	(thread_db_find_new_threads): Use find_first_thread.
21239	(thread_db_get_tls_address): Likewise.
21240
212412007-06-27  Daniel Jacobowitz  <dan@codesourcery.com>
21242
21243	* thread-db.c (thread_db_find_new_threads): Add prototype.
21244	(thread_db_create_event): Check for the main thread before adding
21245	a new thread.
21246	(maybe_attach_thread): Only enable event reporting if TID == 0.
21247	(thread_db_get_tls_address): Check for new threads.
21248
212492007-06-20  Daniel Jacobowitz  <dan@codesourcery.com>
21250
21251	* linux-low.c (linux_create_inferior): Try execv before execvp.
21252	* spu-low.c (spu_create_inferior): Likewise.
21253
212542007-06-13  Mike Frysinger  <vapier@gentoo.org>
21255
21256	* linux-low.c (linux_create_inferior): Change execv to execvp.
21257	* spu-low.c (spu_create_inferior): Likewies.
21258
212592007-06-13  Daniel Jacobowitz  <dan@codesourcery.com>
21260
21261	* Makefile.in (clean): Clean new files instead of deleted ones.
21262	(reg-mips.o, reg-mips.c, reg-mips64.o, reg-mips64.c): Delete.
21263	(mips-linux.o, mips-linux.c, mips64-linux.o, mips64-linux.c): New
21264	rules.
21265	* configure.srv: Specify XML files and new regformats for MIPS and
21266	MIPS64 GNU/Linux.
21267	* linux-mips-low.c (mips_num_regs): Set to only used registers.
21268	(mips_regmap): Do not fetch $0.  Remove unused registers.  Add
21269	an entry for the restart register.
21270	(mips_cannot_fetch_register, mips_cannot_store_register)
21271	(mips_reinsert_addr, mips_fill_fpregset, mips_store_fpregset): Update
21272	register names to match the XML descriptions.
21273	(mips_fill_gregset, mips_store_gregset): Likewise.  Handle the
21274	restart register instead of $0.
21275
212762007-06-12  Ulrich Weigand  <uweigand@de.ibm.com>
21277	    Markus Deuling  <deuling@de.ibm.com>
21278
21279	* remote-utils.c (decode_xfer_write): New function.
21280	* server.h (decode_xfer_write): Add prototype.
21281	* server.c (handle_query): Add PACKET_LEN argument.  Support
21282	qXfer:spu:read and qXfer:spu:write packets.
21283	(main): Pass packet_len to handle_query.
21284	* spu-low.c (spu_target_ops): Add spu_proc_xfer_spu.
21285	* target.h (target_ops): Add qxfer_spu.
21286
212872007-06-12  Ulrich Weigand  <uweigand@de.ibm.com>
21288
21289	* spu-low.c (spu_proc_xfer_spu): Do not return failure when
21290	accessing non-seekable spufs files.
21291
212922007-05-16  Markus Deuling  <deuling@de.ibm.com>
21293
21294	* server.c (handle_query): Add reply for qC packet.
21295
212962007-05-10  Pedro Alves  <pedro_alves@portugalmail.pt>
21297	    Leo Zayas  <lerele@champenstudios@com>
21298
21299	* server.h (check_remote_input_interrupt_request): New function.
21300	* remote_utils.c (INVALID_DESCRIPTOR): New define.
21301	(remote_desc): Initialize with INVALID_DESCRIPTOR.
21302	(input_interrupt): Expose on USE_WIN32API too.  Fix whitespace.
21303	(check_remote_input_interrupt_request): New function.
21304	* server.h (check_remote_input_interrupt_request): Declare.
21305	* win32-low.c (winapi_DebugBreakProcess,
21306	winapi_GenerateConsoleCtrlEvent): New typedefs.
21307	(get_child_debug_event): Lower Win32 debug event polling from 1 sec
21308	to 250 ms.
21309	(win32_wait): Check for remote interrupt request
21310	with check_remote_input_interrupt_request.
21311	(win32_request_interrupt): New function.
21312	(win32_target_op): Set request_interrupt to win32_request_interrupt.
21313
213142007-05-10  Pedro Alves  <pedro_alves@portugalmail.pt>
21315
21316	* win32-low.c (debug_registers_changed,
21317	debug_registers_used, CONTEXT_EXTENDED_REGISTERS,
21318	CONTEXT_FLOATING_POINT, CONTEXT_DEBUG_REGISTERS,
21319	CONTEXT_DEBUGGER, CONTEXT_DEBUGGER_DR): Delete.
21320	(thread_rec): Get context using the low target.
21321	(child_add_thread): Call thread_added on the low target,
21322	which does the same thing.
21323	(regptr): Delete.
21324	(do_initial_child_stuff): Remove debug registers references.
21325	Set context using the low target.  Resume threads after
21326	setting the contexts.
21327	(child_continue): Remove dead variable.  Remove debug
21328	registers references.
21329	(child_fetch_inferior_registers): Go through the low target.
21330	(do_child_store_inferior_registers): Remove.
21331	(child_store_inferior_registers): Go through the low target.
21332	(win32_resume): Remove debug registers references.
21333	Set context using the low target.
21334	(handle_exception): Change return type to void.  Don't record
21335	context here.  Set status to TARGET_WAITKIND_SPURIOUS on a
21336	first chance exception.
21337	(get_child_debug_event): Change return type to void.  Remove
21338	goto loop.  Always return after waiting for debug event.
21339	(win32_wait): Convert to switch statement.  Handle spurious
21340	events.
21341
21342	* win32-i386-low.c (debug_registers_changed,
21343	debug_registers_used): New.
21344	(initial_stuff): Rename to ...
21345	(i386_initial_stuff): ... this.  Clear debug registers
21346	state variables.
21347	(store_debug_registers): Delete.
21348	(i386_get_thread_context): New.
21349	(load_debug_registers): Delete.
21350	(i386_set_thread_context): New.
21351	(i386_thread_added): New.
21352	(single_step): Rename to ...
21353	(i386_single_step): ... this.
21354	(do_fetch_inferior_registers): Rename to ...
21355	(i386_fetch_inferior_register): ... this.
21356	(i386_store_inferior_register): New.
21357	(the_low_target): Adapt to new interface.
21358
21359	* win32-arm-low.c (CONTEXT_FLOATING_POINT): Define.
21360	(arm_get_thread_context): New.
21361	(arm_set_thread_context): New.
21362	(regptr): New.
21363	(do_fetch_inferior_registers): Rename to ...
21364	(arm_fetch_inferior_register): ... this.
21365	(arm_store_inferior_register): New.
21366	(arm_wince_breakpoint): Reimplement as unsigned long.
21367	(arm_wince_breakpoint_len): Define.
21368	(the_low_target): Adapt to new interface.
21369
21370	* win32-low.h (target_ops): Remove regmap, store_debug_registers and
21371	load_debug_registers.  Add get_thread_context, set_thread_context,
21372	thread_added and store_inferior_register.  Rename
21373	fetch_inferior_registers to fetch_inferior_register.
21374	(regptr): Remove declaration.
21375
213762007-05-10  Pedro Alves  <pedro_alves@portugalmail.pt>
21377
21378	* linux-low.c (linux_detach): Change return type to int.  Return 0.
21379	* spu-low.c (spu_detach): Likewise.
21380
213812007-05-10  Pedro Alves  <pedro_alves@portugalmail.pt>
21382
21383	* target.h (target_ops): Change return type of detach to int.
21384	Add join.
21385	(join_inferior): New.
21386	* server.c (main): Don't skip detach support on mingw32.
21387	If the inferior doesn't support detaching return error.
21388	Call join_inferior instead of using waitpid.
21389	* linux-low.c (linux_join): New.
21390	(linux_target_op): Add linux_join.
21391	* spu-low.c (spu_join): New.
21392	(spu_target_ops): Add spu_join.
21393	* win32-low.c (win32_detach): Adapt to new interface.
21394	Reopen current_process_handle before detaching.  Issue a child
21395	resume before detaching.
21396	(win32_join): New.
21397	(win32_target_op): Add win32_join.
21398
213992007-05-10  Pedro Alves  <pedro_alves@portugalmail.pt>
21400
21401	* win32-low.c (win32-attach): Fix return value.
21402	* target.h (target_ops): Describe ATTACH return values.
21403
214042007-05-10  Pedro Alves  <pedro_alves@portugalmail.pt>
21405
21406	* win32-low.c (GETPROCADDRESS): Define.
21407	(winapi_DebugActiveProcessStop): Add WINAPI.  typedef as pointer.
21408	(winapi_DebugSetProcessKillOnExit): Likewise.
21409	(win32_create_inferior): Force usage of ansi CreateProcessA.
21410	(win32_attach): Use GETPROCADDRESS.
21411	(win32_detach): Likewise.
21412
214132007-05-10  Pedro Alves  <pedro_alves@portugalmail.pt>
21414
21415	* win32-low.c (win32_wait): Don't use WSTOPSIG.
21416
214172007-03-30  Pedro Alves  <pedro_alves@portugalmail.pt>
21418
21419	* win32-low.c: Commit leftover changes from 2007-03-29.
21420
214212007-03-30  Daniel Jacobowitz  <dan@codesourcery.com>
21422
21423	* i387-fp.c (struct i387_fsave, struct i387_fxsave): Make 16-bit
21424	fields short instead of int.  Add explicit padding.
21425	(i387_cache_to_fsave): Remove unnecessary casts.
21426	(i387_fsave_to_cache): Doc fix.
21427	(i387_cache_to_fxsave): Remove unnecessary casts and masking.
21428
214292007-03-30  Daniel Jacobowitz  <dan@codesourcery.com>
21430
21431	* i387-fp.c (i387_cache_to_fxsave): Reinitialize val2 before use.
21432	(i387_fxsave_to_cache): Check fp->ftag while building ftag value.
21433
214342007-03-29  Pedro Alves  <pedro_alves@portugalmail.pt>
21435
21436	* configure.srv (arm*-*-mingw32ce*): Move near the other
21437	arm targets.
21438
214392007-03-29  Pedro Alves  <pedro_alves@portugalmail.pt>
21440
21441	* configure.ac: Add errno checking.
21442	(AC_CHECK_HEADERS): Add errno.h, fcntl.h, signal.h,
21443	sys/file.h and malloc.h.
21444	(AC_CHECK_DECLS): Add perror.
21445	(srv_mingwce): Handle.
21446	* configure.srv (i[34567]86-*-cygwin*): Add
21447	win32-i386-low.o to srv_tgtobj.
21448	(i[34567]86-*-mingw*): Likewise.
21449	(arm*-*-mingw32ce*): Add case.
21450	* gdbreplay.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
21451	HAVE_FCNTL_H, HAVE_ERRNO_H, HAVE_MALLOC_H]: Check.
21452	[__MINGW32CE__] (strerror): New function.
21453	[__MINGW32CE__] (errno): Define to GetLastError.
21454	[__MINGW32CE__] (COUNTOF): New macro.
21455	(remote_open): Remove extra close call.
21456	* mem-break.c (delete_breakpoint_at): New function.
21457	* mem-break.h (delete_breakpoint_at): Declare.
21458	* remote-utils.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
21459	HAVE_FCNTL_H, HAVE_UNISTD_H, HAVE_ERRNO_H]: Check.
21460	[USE_WIN32API] (read, write): Add char* casts.
21461	* server.c [HAVE_UNISTD_H, HAVE_SIGNAL_H]: Check.
21462	* server.h: Include wincecompat.h on Windows CE.
21463	[HAVE_ERRNO_H]: Check.
21464	(perror): Declare if not declared.
21465	* utils.c: Add stdlib.h, errno.h and malloc.h includes.
21466	(perror_with_name): Remove errno declaration.
21467	* wincecompat.h: New.
21468	* wincecompat.c: New.
21469	* win32-low.h: New.
21470	* win32-arm-low.c: New.
21471	* win32-i386-low.c: New.
21472	(win32-low.c): Include mem-break.h and win32-low.h, and winnt.h.
21473	(OUTMSG2): Make it safe.
21474	(_T): New macro.
21475	(COUNTOF): New macro.
21476	(NUM_REGS): Get it from the low target.
21477	(CONTEXT_EXTENDED_REGISTERS, CONTEXT_FLOATING_POINT,
21478	CONTEXT_DEBUG_REGISTERS): Add fallbacks to 0.
21479	(thread_rec): Let low target handle debug registers.
21480	(child_add_thread): Likewise.
21481	(child_init_thread_list): Likewise.
21482	(continue_one_thread): Likewise.
21483	(regptr): New.
21484	(do_child_fetch_inferior_registers): Move to ...
21485	* win32-i386-low.c: ... here, and rename to ...
21486	(do_fetch_inferior_registers): ... this.
21487	* win32-low.c (child_fetch_inferior_registers):
21488	Go through the low target.
21489	(do_child_store_inferior_registers): Use regptr.
21490	(strwinerror): New function.
21491	(win32_create_inferior): Handle Windows CE.
21492	Use strwinerror instead of strerror on Windows error
21493	codes.  Add program to the error output.
21494	Don't close the main thread handle on Windows CE.
21495	(win32_attach): Use coredll.dll on Windows CE.
21496	(win32_kill): Close current process and current
21497	thread handles.
21498	(win32_detach): Use coredll.dll on Windows CE.
21499	(win32_resume): Let low target handle debug registers, and
21500	step request.
21501	(handle_exception): Add/Remove initial breakpoint.  Avoid
21502	non-existant WSTOPSIG on Windows CE.
21503	(win32_read_inferior_memory): Cast to remove warning.
21504	(win32_arch_string): Go through the low target.
21505	(initialize_low): Call set_breakpoint_data with the low
21506	target's breakpoint.
21507	* win32-low.c (dr, FLAG_TRACE_BIT, FCS_REGNUM,
21508	FOP_REGNUM, mappings): Move to ...
21509	* win32-i386-low.c: ... here.
21510	* win32-low.c (win32_thread_info): Move to ...
21511	* win32-low.h: ... here.
21512	* Makefile.in (SFILES): Add win32-low.c, win32-i386-low.c,
21513	win32-arm-low.c and wincecompat.c.
21514	(all:): Add $EXEEXT.
21515	(install-only:): Likewise.
21516	(gdbserver:): Likewise.
21517	(gdbreplay:): Likewise.
21518	* config.in: Regenerate.
21519	* configure: Regenerate.
21520
215212007-03-28  Pedro Alves  <pedro_alves@portugalmail.pt>
21522
21523	* win32-low.c: Rename typedef thread_info to
21524	win32_thread_info throughout.
21525
215262007-03-28  Pedro Alves  <pedro_alves@portugalmail.pt>
21527
21528	* win32-i386-low.c: Rename to ...
21529	* win32-low.c: ... this.
21530	* configure.srv: Replace win32-i386-low.o with win32-low.o.
21531	* Makefile.in: Likewise.
21532
215332007-03-27  Pedro Alves  <pedro_alves@portugalmail.pt>
21534
21535	* remote-utils.c (monitor_output): Constify msg parameter.
21536	* server.h (monitor_output): Likewise.
21537	* win32-i386-low.c (handle_output_debug_string): New.
21538	(win32_kill): Handle OUTPUT_DEBUG_STRING_EVENT events using
21539	handle_output_debug_string.
21540	(get_child_debug_event): Likewise.
21541
215422007-03-27  Mat Hostetter  <mat@lcs.mit.edu>
21543
21544	* server.c (main): Correct strtoul check.
21545
215462007-03-27  Jon Ringle  <jon@ringle.org>
21547
21548	* linux-low.c: Check __ARCH_HAS_MMU__ also.
21549
215502007-03-27  Brooks Moses  <brooks.moses@codesourcery.com>
21551
21552	* Makefile.in: Add dummy "pdf" and "install-pdf" targets.
21553
215542007-02-27  Daniel Jacobowitz  <dan@codesourcery.com>
21555
21556	* terminal.h: Check HAVE_SGTTY_H.
21557
215582007-02-27  Mat Hostetter  <mat@lcs.mit.edu>
21559
21560	* remote-utils.c (remote_open): Print out the assigned port number.
21561
215622007-02-26  Daniel Jacobowitz  <dan@codesourcery.com>
21563
21564	* remote-utils.c (monitor_output): New function.
21565	* server.c (debug_threads): Define here.
21566	(monitor_show_help): New function.
21567	(handle_query): Handle qRcmd.
21568	(main): Do not handle 'd' packet.
21569	* server.h (debug_threads, remote_debug, monitor_output): Declare.
21570	* linux-low.c, spu-low.c, win32-i386-low.c: Remove definitions
21571	of debug_threads.
21572
215732007-02-25  Pedro Alves  <pedro_alves@portugalmail.pt>
21574
21575	* Makefile.in (EXEEXT): New.
21576	(clean): Use $(EXEEXT).
21577
215782007-02-25  Pedro Alves  <pedro_alves@portugalmail.pt>
21579
21580	* target.h (target_ops): Rename send_signal to request_interrupt,
21581	and remove enum target_signal parameter.
21582	* linux-low.c (linux_request_interrupt): Rename from
21583	linux_send_signal, and always send SIGINT.
21584	* spu-low.c (spu_request_interrupt): Rename from spu_send_signal,
21585	and always send SIGINT.
21586	* remote-utils.c (putpkt_binary): Call request_interrupt, instead
21587	of send_signal.
21588	(input_interrupt): Likewise.
21589
215902007-02-25  Pedro Alves  <pedro_alves@portugalmail.pt>
21591
21592	* server.c (get_features_xml): Check if target implemented
21593	arch_string.
21594	* win32-i386-low.c (win32_arch_string): New.
21595	(win32_target_ops): Add win32_arch_string as arch_string member.
21596
215972007-02-22  Markus Deuling  <deuling@de.ibm.com>
21598
21599	* spu-low.c (spu_arch_string): New.
21600	(spu_target_ops): Add spu_arch_string.
21601
216022007-02-16  Daniel Jacobowitz  <dan@codesourcery.com>
21603
21604	* remote-utils.c: Remove HAVE_TERMINAL_H check.
21605	* configure.ac: Do not check for terminal.h.
21606	* configure, config.in: Regenerated.
21607
216082007-02-08  Daniel Jacobowitz  <dan@codesourcery.com>
21609
21610	* Makefile.in (OBS): Add $(XML_BUILTIN).
21611	(XML_DIR, XML_TARGET, XML_FILES, XML_BUILTIN): New.
21612	(clean): Update.
21613	(target.xml, xml-builtin.c, stamp-xml, arm-with-iwmmxt.o)
21614	(arm-with-iwmmxt.c): New.
21615	* config.in, configure: Regenerate.
21616	* configure.ac: Check for iWMMXt.  Handle srv_xmltarget,
21617	srv_xmlbuiltin, and srv_xmlfiles.  Define USE_XML.
21618	* configure.srv: Mention srv_xmltarget and srv_xmlfiles.
21619	(arm*-*-linux*): Add iWMMXt and regset support.
21620	* linux-arm-low.c (PTRACE_GETWMMXREGS, PTRACE_SETWMMXREGS): Define.
21621	(arm_fill_gregset, arm_store_gregset, arm_fill_wmmxregset)
21622	(arm_store_wmmxregset, target_regsets): New.
21623	* server.c (get_features_xml): Take annex argument.  Check builtin
21624	XML documents.
21625	(handle_query): Handle multiple annexes.
21626
216272007-01-29  Daniel Jacobowitz  <dan@codesourcery.com>
21628
21629	* remote-utils.c [USE_WIN32API] (read, write): Define.
21630	(putpkt_binary, input_interrupt, readchar, getpkt): Use read and
21631	write.
21632
216332007-01-09  Daniel Jacobowitz  <dan@codesourcery.com>
21634
21635	* linux-i386-low.c (the_low_target): Set arch_string.
21636	* linux-x86-64-low.c (the_low_target): Likewise.
21637	* linux-low.c (linux_arch_string): New.
21638	(linux_target_ops): Add it.
21639	* linux-low.h (struct linux_target_ops): Add arch_string.
21640	* server.c (write_qxfer_response): Use const void * for DATA.
21641	(get_features_xml): New.
21642	(handle_query): Handle qXfer:features:read.  Report it for qSupported.
21643	* target.h (struct target_ops): Add arch_string method.
21644
216452007-01-03  Denis Pilat  <denis.pilat@st.com>
21646	    Daniel Jacobowitz  <dan@codesourcery.com>
21647
21648	* linux-low.c (linux_kill): Handle being called with no threads.
21649	* win32-i386-low.c (win32_kill): Likewise.
21650	(get_child_debug_event): Clear current_process_handle.
21651
216522006-12-30  Denis PILAT  <denis.pilat@st.com>
21653	    Daniel Jacobowitz  <dan@codesourcery.com>
21654
21655	* remote-utils.c (remote_open): Check the type of specified
21656	serial port devices before opening them.
21657	* server.c (main): Kill the inferior if an error occurs during
21658	the first remote_open.
21659
216602006-12-05  Markus Deuling  <deuling@de.ibm.com>
21661
21662	* README: Update supported targets.
21663
216642006-11-28  Daniel Jacobowitz  <dan@codesourcery.com>
21665
21666	* Makefile.in (clean): Remove reg-mips64.c.
21667	(reg-mips64.c, reg-mips64.o): New rules.
21668	* configure.srv: Handle mips64.  Include regset support for mips.
21669	* linux-mips-low.c (union mips_register): New.
21670	(mips_get_pc, mips_set_pc, mips_reinsert_addr): Use it.
21671	(mips_breakpoint, mips_breakpoint_at): Use int.
21672	(mips_collect_register, mips_supply_register)
21673	(mips_collect_register_32bit, mips_supply_register_32bit)
21674	(mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
21675	(mips_store_fpregset, target_regsets): New.
21676	* thread-db.c (thread_db_get_tls_address): Use uintptr_t.
21677
216782006-11-22  Ulrich Weigand  <uweigand@de.ibm.com>
21679
21680	* configure.srv: Add target "spu*-*-*".
21681	* Makefile.in (clean): Remove reg-spu.c.
21682	(reg-spu.c, reg-spu.o, spu-low.o): Add dependencies.
21683	* spu-low.c: New file.
21684
216852006-11-16  Daniel Jacobowitz  <dan@codesourcery.com>
21686
21687	* configure.ac: Correct td_thr_tls_get_addr test.
21688	* configure: Regenerated.
21689
216902006-11-16  Daniel Jacobowitz  <dan@codesourcery.com>
21691
21692	* linux-low.c (linux_wait_for_event): Reformat.  Use the
21693	pass_signals array.
21694	* remote-utils.c (decode_address_to_semicolon): New.
21695	* server.c (pass_signals, handle_general_set): New.
21696	(handle_query): Mention QPassSignals for qSupported.
21697	(main): Call handle_general_set.
21698	* server.h (pass_signals, decode_address_to_semicolon): New.
21699
217002006-11-06  Daniel Jacobowitz  <dan@codesourcery.com>
21701
21702	* server.c (handle_query): Correct error handling for read_auxv.
21703
217042005-10-19  Ulrich Weigand  <uweigand@de.ibm.com>
21705
21706	* configure.srv [s390-*-linux*, s390x-*-linux*]: Set srv_linux_regsets
21707	and srv_linux_thread_db to yes.
21708	* linux-s390-low.c (s390_fill_gregset): New function.
21709	(target_regsets): Define data structure.
21710
217112006-10-17  Daniel Jacobowitz  <dan@codesourcery.com>
21712
21713	* acinclude.m4 (SRV_CHECK_TLS_GET_ADDR): New.
21714	* configure.ac: Use it.  Define HAVE_TD_THR_TLS_GET_ADDR.
21715	* config.in, configure: Regenerated.
21716	* inferiors.c (gdb_id_to_thread): New function.
21717	(gdb_id_to_thread_id): Use it.
21718	* linux-low.c (linux_target_ops): Use thread_db_get_tls_address.
21719	* linux-low.h (struct process_info): Add th member.
21720	(thread_db_get_tls_address): New prototype.
21721	* remote-utils.c (decode_address): Make non-static.
21722	* server.c (handle_query): Handle qGetTLSAddr.
21723	* server.h (gdb_id_to_thread, decode_address): New prototypes.
21724	* target.h (struct target_ops): Add get_tls_address.
21725	* thread-db.c (maybe_attach_thread): Save the thread handle.
21726	(thread_db_get_tls_address): New.
21727
217282006-09-28  Daniel Jacobowitz  <dan@codesourcery.com>
21729
21730	* linux-low.c (PTRACE_GETSIGINFO, PTRACE_SETSIGINFO): Define.
21731	(linux_resume_one_process): Take a siginfo_t *.  Update all
21732	callers.  Queue it if necessary.  Use PTRACE_SETSIGINFO.
21733	(struct pending_signals): Add a siginfo_t.
21734	(linux_wait_for_process): Always set last_status.
21735	(linux_wait_for_event): Use PTRACE_GETSIGINFO.
21736	(linux_queue_one_thread): Use PTRACE_GETSIGINFO.
21737	* linux-low.h (struct process_info): Add last_status.
21738
217392006-09-21  Daniel Jacobowitz  <dan@codesourcery.com>
21740
21741	* remote-utils.c (try_rle): New function.
21742	(putpkt_binary): Use it.
21743
217442006-08-19  Daniel Jacobowitz  <dan@codesourcery.com>
21745
21746	* Makefile.in (clean): Clean reg-x86-64-linux.c.
21747	(reg-x86-64-linux.o, reg-x86-64-linux.c): New.
21748	* configure.srv (x86_64-*-linux*): Use reg-x86-64-linux.o.
21749	* linux-x86-64-low.c (x86_64_regmap): Include ORIG_RAX.
21750	(x86_64_fill_gregset, x86_64_store_gregset): Skip floating
21751	point registers.
21752
217532006-08-08  Richard Sandiford  <richard@codesourcery.com>
21754
21755	* server.c (terminal_fd): New variable.
21756	(old_foreground_pgrp): Likewise.
21757	(restore_old_foreground_pgrp): New function.
21758	(start_inferior): Record the terminal file descriptor in terminal_fd
21759	and its original foreground group in old_foreground_pgrp.  Register
21760	restore_old_foreground_pgrp with atexit().
21761
217622006-07-26  Daniel Jacobowitz  <dan@codesourcery.com>
21763
21764	* server.c (handle_query): Correct qPart to qXfer.
21765
217662006-07-22  Daniel Jacobowitz  <dan@codesourcery.com>
21767
21768	* configure.ac: Check for more headers which are missing on
21769	Windows.  Automatically supply -lwsock32 and USE_WIN32API.
21770	* configure.srv: Add Cygwin and mingw32.
21771	* remote-utils.c: Don't include headers unconditionally which
21772	are missing on mingw32.  Include <winsock.h> for mingw32.
21773	(remote_open): Adjust for mingw32 support.  Flush
21774	standard error after writing to it.
21775	(remote_close, putpkt_binary, input_interrupt, block_async_io)
21776	(unblock_async_io, enable_async_io, disable_async_io)
21777	(readchar, getpkt): Update for Winsock support.
21778	(prepare_resume_reply): Expect a protocol signal number.
21779	* server.c: Disable <sys/wait.h> on mingw32.
21780	(start_inferior): Adjust for mingw32 support.  Flush
21781	standard error after writing to it.
21782	(attach_inferior): Likewise.  Use protocol signal
21783	numbers.
21784	(main): Skip 'D' packet on mingw32.  Use protocol signal numbers
21785	and names.
21786	* win32-i386-low.c: New file.
21787	* Makefile.in (XM_CLIBS): Set.
21788	(gdbserver, gdbreplay): Use $(INTERNAL_CFLAGS).
21789	(win32-i386-low.o): New dependency rule.
21790	* linux-low.c (linux_wait): Use target signal numbers.
21791	* target.h (struct target_ops): Doc fix.
21792	* server.h (target_signal_to_name): New prototype.
21793	* gdbreplay.c: Don't include headers unconditionally which
21794	are missing on mingw32.  Include <winsock.h> for mingw32.
21795	(remote_close, remote_open): Adjust for Winsock support.
21796	* configure, config.in: Regenerated.
21797
217982006-07-12  Daniel Jacobowitz  <dan@codesourcery.com>
21799
21800	* server.c (decode_xfer_read, write_qxfer_response): New.
21801	(handle_query): Take a packet length argument.  Handle
21802	qXfer:auxv:read instead of qPart:auxv:read.  Mention it in
21803	the qSupported response.
21804	(main): Update call to handle_query.
21805
218062006-06-22  Daniel Jacobowitz  <dan@codesourcery.com>
21807
21808	* remote-utils.c (remote_escape_output, remote_unescape_input): New.
21809	(putpkt_binary): Renamed from putpkt and adjusted for binary
21810	data.
21811	(putpkt): New wrapper for putpkt_binary.
21812	(readchar): Don't mask off the high bit.
21813	(decode_X_packet): New function.
21814	* server.c (main): Call putpkt_binary if a handler sets the packet
21815	length.  Save the length of the incoming packet.  Handle 'X'.
21816	* server.h (gdb_byte, remote_escape_output, decode_X_packet): New.
21817
218182006-06-21  Daniel Jacobowitz  <dan@codesourcery.com>
21819
21820	* server.c (handle_query): Handle qSupported.
21821
218222006-05-30  Daniel Jacobowitz  <dan@codesourcery.com>
21823
21824	* remote-utils.c (all_symbols_looked_up): New variable.
21825	(look_up_one_symbol): Check it.
21826	* server.h (look_up_one_symbol): New declaration.
21827	* thread-db.c (thread_db_init): Set all_symbols_looked_up.
21828
218292006-05-30  Daniel Jacobowitz  <dan@codesourcery.com>
21830
21831	* Makefile.in (linux-arm-low.o): Update dependencies.
21832	* linux-arm-low.c: Include "gdb_proc_service.h".
21833	(PTRACE_GET_THREAD_AREA): Define.
21834	(ps_get_thread_area): New function.
21835
218362006-05-09  Nathan Sidwell  <nathan@codesourcery.com>
21837
21838	* configure.srv (m68k*-*-uclinux*): New target.
21839	* linux-low.c (linux_create_inferior): Use vfork on mmuless systems.
21840	(linux_resume_one_process): Remove extraneous cast.
21841	(linux_read_offsets): New.
21842	(linux_target_op): Add linux_read_offsets on mmuless systems.
21843	* server.c (handle_query): Add qOffsets logic.
21844	* target.h (struct target_ops): Add read_offsets.
21845
218462006-03-15  Daniel Jacobowitz  <dan@codesourcery.com>
21847
21848	* linux-mips-low.c: Include <sys/ptrace.h> and "gdb_proc_service.h".
21849	(PTRACE_GET_THREAD_AREA): Define.
21850	(ps_get_thread_area): New function.
21851	* Makefile.in (linux-i386-low.o, linux-mips-low.o)
21852	(linux-x86-64-low.o): Update.
21853
218542006-03-15  Daniel Jacobowitz  <dan@codesourcery.com>
21855
21856	* configure.ac: Remove checks for prfpregset_t.
21857	* gdb_proc_service.h: New file.
21858	* linux-i386-low.c, linux-x86-64-low.c, thread-db.c: Use the
21859	new "gdb_proc_service.h".
21860	* proc-service.c: Likewise.
21861	(ps_pglobal_lookup, ps_pdread, ps_pdwrite): Use psaddr_t.
21862	(ps_lgetfpregs, ps_lsetfpregs): Use a void* argument.
21863	* Makefile.in (gdb_proc_service_h): Updated.
21864	* configure, config.in: Regenerated.
21865
218662006-03-03  Daniel Jacobowitz  <dan@codesourcery.com>
21867
21868	* remote-utils.c (prepare_resume_reply): Move declaration
21869	of gdb_id_from_wait to the top of the block.
21870
218712006-02-15  Daniel Jacobowitz  <dan@codesourcery.com>
21872
21873	* linux-low.c (regsets_store_inferior_registers): Read the regset
21874	from the target before filling it.
21875
218762006-02-08  Daniel Jacobowitz  <dan@codesourcery.com>
21877
21878	* server.c (attach_inferior): Return SIGTRAP for a successful
21879	attach.
21880
218812006-02-01  Daniel Jacobowitz  <dan@codesourcery.com>
21882
21883	* Makefile.in (OBS): Add version.o.
21884	(STAGESTUFF): Delete.
21885	(version.o): Add dependencies.
21886	(version.c): Replace rule.
21887	(clean): Remove version.c.
21888	* server.c (gdbserver_version): New.
21889	(gdbserver_usage): Use printf.
21890	(main): Handle --version and --help.
21891	* server.h (version, host_name): Add declarations.
21892
218932005-12-23  Eli Zaretskii  <eliz@gnu.org>
21894
21895	* linux-arm-low.c:
21896	* linux-arm-low.c:
21897	* inferiors.c:
21898	* i387-fp.h:
21899	* i387-fp.c:
21900	* gdbreplay.c:
21901	* regcache.c:
21902	* proc-service.c:
21903	* mem-break.h:
21904	* mem-break.c:
21905	* linux-x86-64-low.c:
21906	* linux-sh-low.c:
21907	* linux-s390-low.c:
21908	* linux-ppc64-low.c:
21909	* linux-ppc-low.c:
21910	* linux-mips-low.c:
21911	* linux-m68k-low.c:
21912	* linux-m32r-low.c:
21913	* linux-low.h:
21914	* linux-low.c:
21915	* linux-ia64-low.c:
21916	* linux-i386-low.c:
21917	* linux-crisv32-low.c:
21918	* thread-db.c:
21919	* terminal.h:
21920	* target.h:
21921	* target.c:
21922	* server.h:
21923	* server.c:
21924	* remote-utils.c:
21925	* regcache.h:
21926	* utils.c:
21927	* Makefile.in:
21928	* configure.ac:
21929	* gdbserver.1: Add (C) after Copyright.  Update the FSF
21930	address.
21931
219322005-11-13  Daniel Jacobowitz  <dan@codesourcery.com>
21933
21934	* linux-arm-low.c (arm_eabi_breakpoint): New variable.
21935	(arm_breakpoint_at): Recognize both breakpoints.
21936	(the_low_target): Use the correct breakpoint instruction.
21937
219382005-11-02  Daniel Jacobowitz  <dan@codesourcery.com>
21939
21940	* configure.srv (x86_64-*-linux*): Turn on thread_db support.
21941	* linux-x86-64-low.c (x86_64_breakpoint, x86_64_breakpoint_len)
21942	(x86_64_get_pc, x86_64_set_pc, x86_64_breakpoint_at): New.
21943	(the_low_target): Update.
21944
219452005-10-25  Andreas Schwab  <schwab@suse.de>
21946
21947	* server.c (main): Allocate mem_buf with PBUFSIZ bytes.
21948
21949	* linux-ia64-low.c (ia64_regmap): Remove NAT registers.
21950	(ia64_num_regs): Reduce to 462.
21951
219522005-09-17  Daniel Jacobowitz  <dan@codesourcery.com>
21953
21954	* acinclude.m4: Correct quoting.
21955	* aclocal.m4: Regenerated.
21956
21957	Suggested by SZOKOVACS Robert <szo@ies.hu>:
21958	* thread-db.c (thread_db_err_str): Handle TD_VERSION.
21959	(thread_db_init): Call thread_db_err_str.
21960	* configure.ac: Check for TD_VERSION.
21961	* config.in, configure: Regenerated.
21962
219632005-07-31  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>
21964
21965	* server.h (error, fatal, warning): Add ATTR_FORMAT.
21966
219672005-07-13  Daniel Jacobowitz  <dan@codesourcery.com>
21968
21969	* configure.ac: Define HAVE_LINUX_REGSETS even if PTRACE_GETREGS
21970	is not available.  Define HAVE_PTRACE_GETREGS if it is.
21971	* config.in, configure: Regenerated.
21972	* configure.srv: Set srv_linux_regsets for PowerPC and PowerPC64.
21973	* linux-i386-low.c, linux-m68k-low.c: Update to use
21974	HAVE_PTRACE_GETREGS.
21975	* linux-low.c (regsets_fetch_inferior_registers)
21976	(regsets_store_inferior_registers): Only return 0 if we processed
21977	GENERAL_REGS.
21978	* linux-ppc-low.c (ppc_fill_gregset, target_regsets): New.
21979	* linux-ppc64-low.c (ppc_fill_gregset, target_regsets): New.
21980
219812005-07-13  Daniel Jacobowitz  <dan@codesourcery.com>
21982
21983	* inferiors.c (struct thread_info): Add gdb_id.
21984	(add_thread): Add gdb_id argument.
21985	(thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New.
21986	* linux-low.c (linux_create_inferior, linux_attach_lwp): Update
21987	calls to add_thread.
21988	* remote-utils.c (prepare_resume_reply: Use thread_to_gdb_id.
21989	* server.c (handle_query): Use thread_to_gdb_id.
21990	(handle_v_cont, main): Use gdb_id_to_thread_id.
21991	* server.h (add_thread): Update prototype.
21992	(thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New
21993	prototypes.
21994
219952005-07-13  Daniel Jacobowitz  <dan@codesourcery.com>
21996
21997	* linux-low.c (fetch_register, usr_store_inferior_registers): Handle
21998	left-padded registers.
21999	* linux-low.h (struct linux_target_ops): Add left_pad_xfer.
22000	* linux-ppc64-low.c (the_low_target): Set left_pad_xfer.
22001
220022005-07-01  Steve Ellcey  <sje@cup.hp.com>
22003
22004	* configure.ac (BFD_NEED_DECLARATION): Replace with AC_CHECK_DECLS.
22005	* configure: Regenerate.
22006	* config.in: Regenerate.
22007	* server.h (NEED_DECLARATION_STRERROR):
22008	Replace with !HAVE_DECL_STRERROR.
22009
220102005-06-16  Daniel Jacobowitz  <dan@codesourcery.com>
22011
22012	* linux-low.c (linux_wait, linux_send_signal): Don't test
22013	an unsigned long variable for > 0 if it could be MAX_ULONG.
22014	* server.c (myresume): Likewise.
22015	* target.c (set_desired_inferior): Likewise.
22016
220172005-06-13  Mark Kettenis  <kettenis@gnu.org>
22018
22019	* configure.ac: Simplify and improve check for socklen_t.
22020	* configure, config.in: Regenerate.
22021
220222005-06-12  Daniel Jacobowitz  <dan@codesourcery.com>
22023
22024	* acconfig.h: Remove.
22025	* configure.ac: Add a test for socklen_t.  Use three-argument
22026	AC_DEFINE throughout.
22027	* config.in: Regenerated using autoheader 2.59.
22028	* configure: Regenerated.
22029
22030	* gdbreplay.c (socklen_t): Provide a default.
22031	(remote_open): Use socklen_t.
22032	* remote-utils.c (socklen_t): Provide a default.
22033	(remote_open): Use socklen_t.
22034	(convert_int_to_ascii, convert_ascii_to_int, decode_M_packet): Use
22035	unsigned char.
22036
22037	* i387-fp.c (struct i387_fsave, struct i387_fxsave): Use unsigned
22038	char for buffers.
22039	* linux-low.c (linux_read_memory, linux_write_memory)
22040	(linux_read_auxv): Likewise.
22041	* mem-break.c (breakpoint_data, set_breakpoint_data, check_mem_read)
22042	(check_mem_write): Likewise.
22043	* mem-break.h (set_breakpoint_data, check_mem_read, check_mem_write):
22044	Likewise.
22045	* regcache.c (struct inferior_rgcache_data, registers_to_string)
22046	(registers_from_string, register_data): Likewise.
22047	* server.c (handle_query, main): Likewise.
22048	* server.h (convert_ascii_to_int, convert_int_to_ascii)
22049	(decode_M_packet): Likewise.
22050	* target.c (read_inferior_memory, write_inferior_memory): Likewise.
22051	* target.h (struct target_ops): Update read_memory, write_memory,
22052	and read_auxv.
22053	(read_inferior_memory, write_inferior_memory): Update.
22054	* linux-low.h (struct linux_target_ops): Change type of breakpoint
22055	to unsigned char *.
22056	* linux-arm-low.c, linux-cris-low.c, linux-crisv32-low.c,
22057	linux-i386-low.c, linux-m32r-low.c, linux-m68k-low.c,
22058	linux-mips-low.c, linux-ppc-low.c, linux-ppc64-low.c,
22059	linux-s390-low.c, linux-sh-low.c: Update for changes in
22060	read_inferior_memory and the_low_target->breakpoint.
22061
220622005-05-28  Daniel Jacobowitz  <dan@codesourcery.com>
22063
22064	* Makefile.in (SFILES): Add linux-ppc64-low.c.
22065	(linux-ppc64-low.o, reg-ppc64.c, reg-ppc64.o): New targets.
22066	* configure.srv: Add powerpc64-*-linux*.
22067	* linux-ppc64-low.c: New file.
22068
220692005-05-23  Orjan Friberg  <orjanf@axis.com>
22070
22071	* linux-cris-low.c: New file with support for CRIS.
22072	* linux-crisv32-low.c: Ditto for CRISv32.
22073	* Makefile.in (SFILES): Add linux-cris-low.c, linux-crisv32-low.c.
22074	(clean): Add reg-cris.c and reg-crisv32.c.
22075	Add linux-cris-low.o, linux-crisv32-low.o, reg-cris.o, reg-cris.c,
22076	reg-crisv32.o, and reg-crisv32.c to make rules.
22077	* configure.srv: Add cris-*-linux* and crisv32-*-linux* to list of
22078	recognized targets.
22079
220802005-05-16  Ulrich Weigand  <uweigand@de.ibm.com>
22081
22082	* linux-low.c (fetch_register): Ensure buffer size is a multiple
22083	of sizeof (PTRACE_XFER_TYPE).
22084	(usr_store_inferior_registers): Likewise.  Zero out excess bytes.
22085
220862005-05-12  Orjan Friberg  <orjanf@axis.com>
22087
22088	* target.h (struct target_ops): Add insert_watchpoint,
22089	remove_watchpoint, stopped_by_watchpoint, stopped_data_address function
22090	pointers for hardware watchpoint support.
22091	* linux-low.h (struct linux_target_ops): Ditto.
22092	* linux-low.c (linux_insert_watchpoint, linux_remove_watchpoint)
22093	(linux_stopped_by_watchpoint, linux_stopped_data_address): New.  Add
22094	to linux_target_ops.
22095	* remote-utils.c (prepare_resume_reply): Add watchpoint information to
22096	reply packet.
22097	* server.c (main): Recognize 'Z' and 'z' packets.
22098
220992005-05-10  Ulrich Weigand  <uweigand@de.ibm.com>
22100
22101	* linux-s390-low.c (s390_breakpoint, s390_breakpoint_len): Define.
22102	(s390_get_pc, s390_set_pc, s390_breakpoint_at): New functions.
22103	(the_low_target): Add new members.
22104
221052005-05-04  Daniel Jacobowitz  <dan@codesourcery.com>
22106
22107	* proc-service.c (ps_lgetregs): Search all_processes instead of
22108	all_threads.
22109
221102005-05-04  Daniel Jacobowitz  <dan@codesourcery.com>
22111
22112	* server.c (start_inferior): Change return type to int.
22113	(attach_inferior): Change sigptr to int *.
22114	(handle_v_cont, handle_v_requests): Change signal to int *.
22115	(main): Change signal to int.
22116
221172005-04-15  Kei Sakamoto  <sakamoto.kei@renesas.com>
22118
22119	* Makefile.in: Add linux-m32r-low.o, reg-m32r.c and reg-m32r.o.
22120	* configure.srv: Add m32r*-*-linux*.
22121	* linux-m32r-low.c: New file.
22122
221232005-03-04  Daniel Jacobowitz  <dan@codesourcery.com>
22124
22125	* Makefile.in (stamp-h): Set CONFIG_HEADERS explicitly.
22126
221272005-03-03  Daniel Jacobowitz  <dan@codesourcery.com>
22128
22129	* inferiors.c (change_inferior_id, add_thread, find_inferior_id):
22130	Take unsigned long arguments for PIDs.
22131	* linux-low.c (add_process, linux_attach_lwp, linux_attach)
22132	(linux_thread_alive, linux_wait_for_event, kill_lwp, send_sigstop)
22133	(wait_for_sigstop, linux_resume_one_process)
22134	(regsets_fetch_inferior_registers, linux_send_signal)
22135	(linux_read_auxv): Likewise.  Update the types of variables holding
22136	PIDs.  Update format string specifiers.
22137	* linux-low.h (struct process_info, linux_attach_lwp): Likewise.
22138	* remote-utils.c (prepare_resume_reply): Likewise.
22139	* server.c (cont_thread, general_thread, step_thread)
22140	(thread_from_wait, old_thread_from_wait, signal_pid): Change type to
22141	unsigned long.
22142	(handle_query): Update format specifiers.
22143	(handle_v_cont, main): Use strtoul for thread IDs.
22144	* server.h (struct inferior_list_entry): Use unsigned long for ID.
22145	(add_thread, find_inferior_id, change_inferior_id, cont_thread)
22146	(general_thread, step_thread, thread_from_wait)
22147	(old_thread_from_wait): Update.
22148	* target.h (struct thread_resume): Use unsigned long for THREAD.
22149	(struct target_ops): Use unsigned long for arguments to attach and
22150	thread_alive.
22151
221522005-02-24  Daniel Jacobowitz  <dan@codesourcery.com>
22153
22154	* acinclude.m4: Include bfd/bfd.m4 directly.
22155	* configure.ac: Use AC_ARG_PROGRAM.  Suggested by Aron Griffis
22156	<agriffis@toolchain.org>.
22157	* aclocal.m4, configure: Regenerated.
22158
221592005-01-07  Andrew Cagney  <cagney@gnu.org>
22160
22161	* configure.ac: Rename configure.in, require autoconf 2.59.
22162	* configure: Re-generate.
22163
221642004-12-08  Daniel Jacobowitz  <dan@debian.org>
22165
22166	* acinclude.m4 (SRV_CHECK_THREAD_DB): Add ps_get_thread_area.  Reset
22167	LIBS when finished.
22168	* aclocal.m4: Regenerated.
22169	* configure: Regenerated.
22170
221712004-11-21  Andreas Schwab  <schwab@suse.de>
22172
22173	* linux-m68k-low.c (m68k_num_gregs): Define.
22174	(m68k_fill_gregset, m68k_store_gregset, m68k_fill_fpregset)
22175	(m68k_store_fpregset, target_regsets) [HAVE_LINUX_REGSETS]: New.
22176	(m68k_breakpoint, m68k_breakpoint_len, m68k_get_pc, m68k_set_pc)
22177	(m68k_breakpoint_at): New.  Add to the_low_target.
22178
22179	* configure.srv (m68*-*-linux*): Set srv_linux_regsets and
22180	srv_linux_thread_db to yes.
22181
221822004-10-20  Joel Brobecker  <brobecker@gnat.com>
22183
22184	* linux-x86-64-low.c (ARCH_SET_GS): Add definition if missing.
22185	(ARCH_SET_FS): Likewise.
22186	(ARCH_GET_FS): Likewise.
22187	(ARCH_GET_GS): Likewise.
22188
221892004-10-16  Daniel Jacobowitz  <dan@debian.org>
22190
22191	* linux-i386-low.c (ps_get_thread_area): New.
22192	* linux-x86-64-low.c (ps_get_thread_area): New.
22193	* linux-low.c: Include <sys/syscall.h>.
22194	(linux_kill_one_process): Don't kill the first thread here.
22195	(linux_kill): Kill the first thread here.
22196	(kill_lwp): New function.
22197	(send_sigstop, linux_send_signal): Use it.
22198	* proc-service.c: Clean up #ifdefs.
22199	(fpregset_info): Delete.
22200	(ps_lgetregs): Update and enable implementation.
22201	(ps_lsetregs, ps_lgetfpregs, ps_lsetfpregs): Remove disabled
22202	implementations.
22203	* remote-utils.c (struct sym_cache, symbol_cache): New.
22204	(input_interrupt): Print a clearer message.
22205	(async_io_enabled): New variable.
22206	(enable_async_io, disable_async_io): Use it.  Update comments.
22207	(look_up_one_symbol): Use the symbol cache.
22208	* thread-db.c (thread_db_look_up_symbols): New function.
22209	(thread_db_init): Update comments.  Call thread_db_look_up_symbols.
22210
222112004-10-16  Daniel Jacobowitz  <dan@debian.org>
22212
22213	* configure.in: Test for -rdynamic.
22214	* configure: Regenerated.
22215	* Makefile (INTERNAL_LDFLAGS): New.
22216	(gdbserver, gdbreplay): Use it.
22217
222182004-09-02  Andrew Cagney  <cagney@gnu.org>
22219
22220	* Makefile.in (TAGS): Replace TM_FILE with DEPRECATED_TM_FILE.
22221
222222004-03-23  Daniel Jacobowitz  <drow@mvista.com>
22223
22224	* linux-low.c (linux_wait): Clear all_processes list also.
22225
222262004-03-12  Daniel Jacobowitz  <drow@mvista.com>
22227
22228	* linux-low.c: Include <errno.h>.  Remove extern declaration of
22229	errno.
22230
222312004-03-12  Daniel Jacobowitz  <drow@mvista.com>
22232
22233	* gdbreplay.c, server.h, utils.c: Update copyright years.
22234
222352004-03-04  Nathan J. Williams  <nathanw@wasabisystems.com>
22236
22237	* server.c (main): Print child status or termination signal from
22238	variable 'signal', not 'sig'.
22239
222402004-03-04  Nathan J. Williams  <nathanw@wasabisystems.com>
22241
22242	* linux-low.c (linux_read_memory): Change return type to
22243	int.  Check for and return error from ptrace().
22244	* target.c (read_inferior_memory): Change return type to int.  Pass
22245	back return status from the_target->read_memory().
22246	* target.h (struct target_ops): Adapt *read_memory() prototype.
22247	Update comment.
22248	(read_inferior_memory): Adapt prototype.
22249	* server.c (main): Return an error packet if
22250	read_inferior_memory() returns an error.
22251
222522004-03-04  Daniel Jacobowitz  <drow@mvista.com>
22253
22254	* Makefile.in (distclean): Remove config.h, stamp-h, and config.log.
22255	Unify with other clean targets.
22256
222572004-02-29  Daniel Jacobowitz  <drow@mvista.com>
22258
22259	* server.c (handle_v_cont): Call set_desired_inferior.
22260
222612004-02-29  Daniel Jacobowitz  <drow@mvista.com>
22262
22263	* remote-utils.c (prepare_resume_reply): Always supply "thread:".
22264
222652004-02-29  Daniel Jacobowitz  <drow@mvista.com>
22266
22267	* linux-low.c (linux_wait): Unblock async I/O.
22268	(linux_resume): Block and enable async I/O.
22269	* remote-utils.c (block_async_io, unblock_async_io): New functions.
22270	* server.h (block_async_io, unblock_async_io): Add prototypes.
22271
222722004-02-29  Daniel Jacobowitz  <drow@mvista.com>
22273
22274	* remote-utils.c (remote_open): Print a status notice after
22275	opening a TCP port.
22276	* server.c (attach_inferior): Print a status notice after
22277	attaching.
22278
222792004-02-29  Daniel Jacobowitz  <drow@mvista.com>
22280
22281	* linux-arm-low.c (arm_get_pc): Print out stop PC in debug mode.
22282
222832004-02-26  Daniel Jacobowitz  <drow@mvista.com>
22284
22285	* remote-utils.c (write_enn): Use "E01" instead of "ENN" for the
22286	error packet.
22287	* server.c, target.h: Update copyright years.
22288
222892004-02-25  Roland McGrath  <roland@redhat.com>
22290
22291	* target.h (struct target_ops): New member `read_auxv'.
22292	* server.c (handle_query): Handle qPart:auxv:read: query using that.
22293	* linux-low.c (linux_read_auxv): New function.
22294	(linux_target_ops): Initialize `read_auxv' member to that.
22295
222962004-02-17  Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
22297
22298	Committed by Jim Blandy  <jimb@redhat.com>.
22299
22300	* linux-s390-low.c (s390_num_regs): Update.
22301	(s390_regmap): Remove control registers.  Use __s390x__ predefine
22302	instead of GPR_SIZE to distiguish s390 and s390x targets.
22303
223042004-01-31  Daniel Jacobowitz  <drow@mvista.com>
22305
22306	* linux-low.c: Update copyright year.
22307	(check_removed_breakpoint): Clear pending_is_breakpoint.
22308	(linux_set_resume_request, linux_queue_one_thread)
22309	(resume_status_pending_p): New functions.
22310	(linux_continue_one_thread): Use process->resume.
22311	(linux_resume): Only resume threads if there are no pending events.
22312	* linux-low.h (struct process_info): Add resume request
22313	pointer.
22314
223152004-01-30  Daniel Jacobowitz  <drow@mvista.com>
22316
22317	* regcache.c (new_register_cache): Clear the allocated register
22318	buffer.  Suggested by Atsushi Nemoto <anemo@mba.ocn.ne.jp>.
22319
223202003-10-13  Daniel Jacobowitz  <drow@mvista.com>
22321
22322	* linux-low.c (linux_resume): Take a struct thread_resume *
22323	argument.
22324	(linux_wait): Update call.
22325	(resume_ptr): New static variable.
22326	(linux_continue_one_thread): Renamed from
22327	linux_continue_one_process.  Use resume_ptr.
22328	(linux_resume): Use linux_continue_one_thread.
22329	* server.c (handle_v_cont, handle_v_requests): New functions.
22330	(myresume): New function.
22331	(main): Handle 'v' case.
22332	* target.h (struct thread_resume): New type.
22333	(struct target_ops): Change argument of "resume" to struct
22334	thread_resume *.
22335	(myresume): Delete macro.
22336
223372003-08-08  H.J. Lu  <hongjiu.lu@intel.com>
22338
22339	* Makefile.in (install-only): Create dest dir. Support DESTDIR.
22340	(uninstall): Support DESTDIR.
22341
22342Mon Jul 21 20:09:34 UTC 2003  Brendan Conoboy  <blc@redhat.com>
22343
22344	* configure.srv: Add xscale*linux copy of arm*linux entry.
22345
223462003-07-24  Daniel Jacobowitz  <drow@mvista.com>
22347
22348	* linux-arm-low.c (arm_reinsert_addr): New function.
22349	(the_low_target): Add arm_reinsert_addr.
22350
223512003-07-08  Mark Kettenis  <kettenis@gnu.org>
22352
22353	* mem-break.c: Remove whitespace at end of file.
22354
223552003-06-28  Daniel Jacobowitz  <drow@mvista.com>
22356
22357	* configure.in: Check whether we need to prototype strerror.
22358	* server.h: Optionally prototype strerror.
22359	* gdbreplay.c (perror_with_name): Use strerror.
22360	* linux-low.c (linux_attach_lwp): Use strerror.
22361	* utils.c (perror_with_name): Use strerror.
22362	* config.in, configure: Regenerated.
22363
223642003-06-28  Daniel Jacobowitz  <drow@mvista.com>
22365
22366	* linux-sh-low.c (sh_regmap): Fix FP register offsets, reported by
22367	SUGIOKA Toshinobu <sugioka@itonet.co.jp>.
22368
223692003-06-20  Daniel Jacobowitz  <drow@mvista.com>
22370
22371	* Makefile.in (SFILES): Update.
22372	* low-hppabsd.c, low-lynx.c, low-nbsd.c, low-sim.c, low-sparc.c,
22373	low-sun3.c: Remove files.
22374
223752003-06-17  Daniel Jacobowitz  <drow@mvista.com>
22376
22377	* linux-low.c: Move comment to linux_thread_alive where it belonged.
22378	(linux_detach_one_process, linux_detach): New functions.
22379	(linux_target_ops): Add linux_detach.
22380	* server.c (main): Handle 'D' packet.
22381	* target.h (struct target_ops): Add "detach" member.
22382	(detach_inferior): Define.
22383
223842003-06-13  Mark Kettenis  <kettenis@gnu.org>
22385
22386	From Kelley Cook  <kelleycook@wideopenwest.com>:
22387	* configure.srv: Accept i[34567]86 variants.
22388
223892003-06-05  Daniel Jacobowitz  <drow@mvista.com>
22390
22391	* linux-low.c (linux_wait_for_event): Correct comment typos.
22392	(linux_resume_one_process): Call check_removed_breakpoint.
22393	(linux_send_signal): New function.
22394	(linux_target_ops): Add linux_send_signal.
22395	* remote-utils.c (putpkt, input_interrupt): Use send_signal instead
22396	of kill.
22397	* target.h (struct target_ops): Add send_signal.
22398
223992003-05-29  Jim Blandy  <jimb@redhat.com>
22400
22401	* linux-low.c (usr_store_inferior_registers): Transfer buf in
22402	PTRACE_XFER_TYPE-sized chunks, not int-sized chunks.  Otherwise,
22403	if 'int' is smaller than PTRACE_XFER_TYPE, you end up throwing
22404	away part of the register's value.
22405
224062003-03-26  Daniel Jacobowitz  <drow@mvista.com>
22407
22408	* linux-low.c (linux_create_inferior): Use __SIGRTMIN.
22409	(linux_wait_for_event, linux_init_signals): Likewise.
22410
224112003-03-17  Daniel Jacobowitz  <drow@mvista.com>
22412
22413	* configure.in: Check for stdlib.h.
22414	* configure: Regenerated.
22415	* config.in: Regenerated.
22416
224172003-01-04  Andreas Schwab  <schwab@suse.de>
22418
22419	* linux-m68k-low.c (m68k_num_regs): Define to 29 instead of 31.
22420
224212003-01-02  Andrew Cagney  <ac131313@redhat.com>
22422
22423	* Makefile.in: Remove obsolete code.
22424
224252002-11-20  Daniel Jacobowitz  <drow@mvista.com>
22426
22427	* linux-s390-low.c (s390_regmap): Check GPR_SIZE instead of
22428	defined(PT_FPR0_HI).
22429
224302002-11-17  Stuart Hughes  <seh@zee2.com>
22431
22432	* linux-arm-low.c (arm_num_regs): Increase.
22433	(arm_regmap): Include status register.
22434
224352002-11-17  Daniel Jacobowitz  <drow@mvista.com>
22436
22437	* linux-low.c (register_addr): Remove incorrect -1 check.
22438
224392002-08-29  Daniel Jacobowitz  <drow@mvista.com>
22440
22441	* linux-low.c (linux_create_inferior): Call setpgid.  Return
22442	the new PID.
22443	(unstopped_p, linux_signal_pid): Remove.
22444	(linux_target_ops): Remove linux_signal_pid.
22445	* remote-utils.c (putpkt, input_interrupt): Use signal_pid
22446	global instead of target method.
22447	* target.h (struct target_ops): Remove signal_pid.  Update comment
22448	for create_inferior.
22449	* server.c (signal_pid): New variable.
22450	(create_inferior): Set signal_pid.  Block SIGTTOU and SIGTTIN in
22451	gdbserver.  Set the child to be the foreground process group.
22452	(attach_inferior): Set signal_pid.
22453
224542002-08-23  Daniel Jacobowitz  <drow@mvista.com>
22455
22456	* ChangeLog: New file, with entries from gdb/ChangeLog after GDB 5.2.
22457
224582002-08-20  Jim Blandy  <jimb@redhat.com>
22459
22460	* Makefile.in (LDFLAGS): Allow the configure script to establish a
22461	default for this.
22462
224632002-08-01  Andrew Cagney  <cagney@redhat.com>
22464
22465	* Makefile.in: Make chill references obsolete.
22466
224672002-07-24  Kevin Buettner  <kevinb@redhat.com>
22468
22469	* configure.in (unistd.h): Add to AC_CHECK_HEADERS list.
22470	* configure: Regenerate.
22471	* config.in: Regenerate.
22472
224732002-07-09  David O'Brien  <obrien@FreeBSD.org>
22474
22475	* gdbreplay.c (stdlib.h, unistd.h): Conditionaly include.
22476	(perror_with_name, remote_close, remote_open, expect, play): Static.
22477
224782002-07-04  Michal Ludvig  <mludvig@suse.cz>
22479
22480	* linux-x86-64-low.c (x86_64_regmap): Make it an array of
22481	byte offsets instead of an array of indexes.
22482	(x86_64_store_gregset, x86_64_store_fpregset): Parameter made const.
22483
224842002-06-13  Daniel Jacobowitz  <drow@mvista.com>
22485
22486	* regcache.c: Add comment.
22487
224882002-06-11  Daniel Jacobowitz  <drow@mvista.com>
22489
22490	* thread-db.c: New file.
22491	* proc-service.c: New file.
22492	* acinclude.m4: New file.
22493	* Makefile.in: Add GDBSERVER_LIBS, gdb_proc_service_h,
22494	proc-service.o, and thread-db.o.
22495	(linux-low.o): Add USE_THREAD_DB.
22496	* acconfig.h: Add HAVE_PRGREGSET_T, HAVE_PRFPREGSET_T,
22497	HAVE_LWPID_T, HAVE_PSADDR_T, and PRFPREGSET_T_BROKEN.
22498	* aclocal.m4: Regenerated.
22499	* config.in: Regenerated.
22500	* configure: Regenerated.
22501	* configure.in: Check for proc_service.h, sys/procfs.h,
22502	thread_db.h, and linux/elf.h headrs.
22503	Check for lwpid_t, psaddr_t, prgregset_t, prfpregset_t, and
22504	PRFPREGSET_T_BROKEN.  Introduce srv_thread_depfiles and USE_THREAD_DB.
22505	Check for -lthread_db and thread support.
22506	* configure.srv: Enable thread_db support for ARM, i386, MIPS,
22507	PowerPC, and SuperH.
22508	* i387-fp.c: Constify arguments.
22509	* i387-fp.h: Likewise.
22510	* inferiors.c: (struct thread_info): Renamed from
22511	`struct inferior_info'.  Remove PID member.  Use generic inferior
22512	list header.  All uses updated.
22513	(inferiors, signal_pid): Removed.
22514	(all_threads): New variable.
22515	(get_thread): Define.
22516	(add_inferior_to_list): New function.
22517	(for_each_inferior): New function.
22518	(change_inferior_id): New function.
22519	(add_inferior): Removed.
22520	(remove_inferior): New function.
22521	(add_thread): New function.
22522	(free_one_thread): New function.
22523	(remove_thread): New function.
22524	(clear_inferiors): Use for_each_inferior and free_one_thread.
22525	(find_inferior): New function.
22526	(find_inferior_id): New function.
22527	(inferior_target_data): Update argument type.
22528	(set_inferior_target_data): Likewise.
22529	(inferior_regcache_data): Likewise.
22530	(set_inferior_regcache_data): Likewise.
22531	* linux-low.c (linux_bp_reinsert): Remove.
22532	(all_processes, stopping_threads, using_thrads)
22533	(struct pending_signals, debug_threads, pid_of): New.
22534	(inferior_pid): Replace with macro.
22535	(struct inferior_linux_data): Remove.
22536	(get_stop_pc, add_process): New functions.
22537	(linux_create_inferior): Restore SIGRTMIN+1 before calling exec.
22538	Use add_process and add_thread.
22539	(linux_attach_lwp): New function, based on old linux_attach.  Use
22540	add_process and add_thread.  Set stop_expected for new threads.
22541	(linux_attach): New function.
22542	(linux_kill_one_process): New function.
22543	(linux_kill): Kill all LWPs.
22544	(linux_thread_alive): Use find_inferior_id.
22545	(check_removed_breakpoints, status_pending_p): New functions.
22546	(linux_wait_for_process): Renamed from linux_wait_for_one_inferior.
22547	Update.  Use WNOHANG.  Wait for cloned processes also.  Update process
22548	struct for the found process.
22549	(linux_wait_for_event): New function.
22550	(linux_wait): Use it.  Support LWPs.
22551	(send_sigstop, wait_for_sigstop, stop_all_processes)
22552	(linux_resume_one_process, linux_continue_one_process): New functions.
22553	(linux_resume): Support LWPs.
22554	(REGISTER_RAW_SIZE): Remove.
22555	(fetch_register): Use register_size instead.  Call supply_register.
22556	(usr_store_inferior_registers): Likewise.  Call collect_register.
22557	Fix recursive case.
22558	(regsets_fetch_inferior_registers): Improve error message.
22559	(regsets_store_inferior_registers): Add debugging.
22560	(linux_look_up_symbols): Call thread_db_init if USE_THREAD_DB.
22561	(unstopped_p, linux_signal_pid): New functions.
22562	(linux_target_ops): Add linux_signal_pid.
22563	(linux_init_signals): New function.
22564	(initialize_low): Call it.  Initialize using_threads.
22565	* regcache.c (inferior_regcache_data): Add valid
22566	flag.
22567	(get_regcache): Fetch registers lazily.  Add fetch argument
22568	and update all callers.
22569	(regcache_invalidate_one, regcache_invalidate): New
22570	functions.
22571	(new_register_cache): Renamed from create_register_cache.
22572	Return the new regcache.
22573	(free_register_cache): Change argument to a void *.
22574	(registers_to_string, registers_from_string): Call get_regcache
22575	with fetch flag set.
22576	(register_data): Make static.  Pass fetch flag to get_regcache.
22577	(supply_register): Call get_regcache with fetch flag clear.
22578	(collect_register): Call get_regcache with fetch flag set.
22579	(collect_register_as_string): New function.
22580	* regcache.h: Update.
22581	* remote-utils.c (putpkt): Flush after debug output and use
22582	stderr.
22583	Handle input interrupts while waiting for an ACK.
22584	(input_interrupt): Use signal_pid method.
22585	(getpkt): Flush after debug output and use stderr.
22586	(outreg): Use collect_register_as_string.
22587	(new_thread_notify, dead_thread_notify): New functions.
22588	(prepare_resume_reply): Check using_threads.  Set thread_from_wait
22589	and general_thread.
22590	(look_up_one_symbol): Flush after debug output.
22591	* server.c (step_thread, server_waiting): New variables.
22592	(start_inferior): Don't use signal_pid.  Update call to mywait.
22593	(attach_inferior): Update call to mywait.
22594	(handle_query): Handle qfThreadInfo and qsThreadInfo.
22595	(main): Don't fetch/store registers explicitly.  Use
22596	set_desired_inferior.  Support proposed ``Hs'' packet.  Update
22597	calls to mywait.
22598	* server.h: Update.
22599	(struct inferior_list, struct_inferior_list_entry): New.
22600	* target.c (set_desired_inferior): New.
22601	(write_inferior_memory): Constify.
22602	(mywait): New function.
22603	* target.h: Update.
22604	(struct target_ops): New signal_pid method.
22605	(mywait): Removed macro, added prototype.
22606
22607	* linux-low.h (regset_func): Removed.
22608	(regset_fill_func, regset_store_func): New.
22609	(enum regset_type): New.
22610	(struct regset_info): Add type field.  Use new operation types.
22611	(struct linux_target_ops): stop_pc renamed to get_pc.
22612	Add decr_pc_after_break and breakpoint_at.
22613	(get_process, get_thread_proess, get_process_thread)
22614	(strut process_info, all_processes, linux_attach_lwp)
22615	(thread_db_init): New.
22616
22617	* linux-arm-low.c (arm_get_pc, arm_set_pc,
22618	arm_breakpoint, arm_breakpoint_len, arm_breakpoint_at): New.
22619	(the_low_target): Add new members.
22620	* linux-i386-low.c (i386_store_gregset, i386_store_fpregset)
22621	(i386_store_fpxregset): Constify.
22622	(target_regsets): Add new kind identifier.
22623	(i386_get_pc): Renamed from i386_stop_pc.  Simplify.
22624	(i386_set_pc): Add debugging.
22625	(i386_breakpoint_at): New function.
22626	(the_low_target): Add new members.
22627	* linux-mips-low.c (mips_get_pc, mips_set_pc)
22628	(mips_breakpoint, mips_breakpoint_len, mips_reinsert_addr)
22629	(mips_breakpoint_at): New.
22630	(the_low_target): Add new members.
22631	* linux-ppc-low.c (ppc_get_pc, ppc_set_pc)
22632	(ppc_breakpoint, ppc_breakpoint_len, ppc_breakpoint_at): New.
22633	(the_low_target): Add new members.
22634	* linux-sh-low.c (sh_get_pc, sh_set_pc)
22635	(sh_breakpoint, sh_breakpoint_len, sh_breakpoint_at): New.
22636	(the_low_target): Add new members.
22637	* linux-x86-64-low.c (target_regsets): Add new kind
22638	identifier.
22639
226402002-05-15  Daniel Jacobowitz  <drow@mvista.com>
22641
22642	From Martin Pool <mbp@samba.org>:
22643	* server.c (gdbserver_usage): New function.
22644	(main): Call it.
22645
226462002-05-14  Daniel Jacobowitz  <drow@mvista.com>
22647
22648	* mem-break.c (reinsert_breakpoint_by_bp): Correct typo
22649	stop_at -> stop_pc.
22650
226512002-05-04  Andrew Cagney  <ac131313@redhat.com>
22652
22653	* Makefile.in: Remove obsolete code.
22654
226552002-04-24  Michal Ludvig  <mludvig@suse.cz>
22656
22657	* linux-low.c (regsets_fetch_inferior_registers),
22658	(regsets_store_inferior_registers): Removed cast to int from
22659	ptrace() calls.
22660	* regcache.h: Added declaration of struct inferior_info.
22661
226622002-04-20  Daniel Jacobowitz  <drow@mvista.com>
22663
22664	* inferiors.c (struct inferior_info): Add regcache_data.
22665	(add_inferior): Call create_register_cache.
22666	(clear_inferiors): Call free_register_cache.
22667	(inferior_regcache_data, set_inferior_regcache_data): New functions.
22668	* regcache.c (struct inferior_regcache_data): New.
22669	(registers): Remove.
22670	(get_regcache): New function.
22671	(create_register_cache, free_register_cache): New functions.
22672	(set_register_cache): Don't initialize the register cache here.
22673	(registers_to_string, registers_from_string, register_data): Call
22674	get_regcache.
22675	* regcache.h: Add prototypes.
22676	* server.h: Likewise.
22677
226782002-04-20  Daniel Jacobowitz  <drow@mvista.com>
22679
22680	* mem-break.c: New file.
22681	* mem-break.h: New file.
22682	* Makefile.in: Add mem-break.o rule; update server.h
22683	dependencies.
22684	* inferiors.c (struct inferior_info): Add target_data
22685	member.
22686	(clear_inferiors): Free target_data member if set.
22687	(inferior_target_data, set_inferior_target_data): New functions.
22688	* linux-i386-low.c (i386_breakpoint, i386_breakpoint_len)
22689	(i386_stop_pc, i386_set_pc): New.  Add to the_low_target.
22690	* linux-low.c (linux_bp_reinsert): New variable.
22691	(struct inferior_linux_data): New.
22692	(linux_create_inferior): Use set_inferior_target_data.
22693	(linux_attach): Likewise.  Call add_inferior.
22694	(linux_wait_for_one_inferior): New function.
22695	(linux_wait): Call it.
22696	(linux_write_memory): Add const.
22697	(initialize_low): Call set_breakpoint_data.
22698	* linux-low.h (struct linux_target_ops): Add breakpoint
22699	handling members.
22700	* server.c (attach_inferior): Remove extra add_inferior
22701	call.
22702	* server.h: Include mem-break.h.  Update inferior.c
22703	prototypes.
22704	* target.c (read_inferior_memory)
22705	(write_inferior_memory): New functions.
22706	* target.h (read_inferior_memory)
22707	(write_inferior_memory): Change macros to prototypes.
22708	(struct target_ops): Update comments.  Add const to write_memory
22709	definition.
22710
227112002-04-11  Daniel Jacobowitz  <drow@mvista.com>
22712
22713	* linux-low.c (usr_store_inferior_registers): Support
22714	registers which are allowed to fail to store.
22715	* linux-low.h (linux_target_ops): Likewise.
22716	* linux-ppc-low.c (ppc_regmap): Support FPSCR.
22717	(ppc_cannot_store_register): FPSCR may not be storable.
22718
227192002-04-09  Daniel Jacobowitz  <drow@mvista.com>
22720
22721	* server.h: Include <string.h> if HAVE_STRING_H.
22722	* ChangeLog: Correct paths in last ChangeLog entry.
22723
227242002-04-09  Daniel Jacobowitz  <drow@mvista.com>
22725
22726	* linux-low.h: Remove obsolete prototypes.
22727	(struct linux_target_ops): New.
22728	(extern the_low_target): New.
22729	* linux-low.c (num_regs, regmap): Remove declarations.
22730	(register_addr): Use the_low_target explicitly.
22731	(fetch_register): Likewise.
22732	(usr_fetch_inferior_registers): Likewise.
22733	(usr_store_inferior_registers): Likewise.
22734	* linux-arm-low.c (num_regs): Remove.
22735	(arm_num_regs): Define.
22736	(arm_regmap): Renamed from regmap, made static.
22737	(arm_cannot_fetch_register): Renamed from cannot_fetch_register,
22738	made static.
22739	(arm_cannot_store_register): Renamed from cannot_store_register,
22740	made static.
22741	(the_low_target): New.
22742	* linux-i386-low.c (num_regs): Remove.
22743	(i386_num_regs): Define.
22744	(i386_regmap): Renamed from regmap, made static.
22745	(i386_cannot_fetch_register): Renamed from cannot_fetch_register,
22746	made static.
22747	(i386_cannot_store_register): Renamed from cannot_store_register,
22748	made static.
22749	(the_low_target): New.
22750	* linux-ia64-low.c (num_regs): Remove.
22751	(ia64_num_regs): Define.
22752	(ia64_regmap): Renamed from regmap, made static.
22753	(ia64_cannot_fetch_register): Renamed from cannot_fetch_register,
22754	made static.
22755	(ia64_cannot_store_register): Renamed from cannot_store_register,
22756	made static.
22757	(the_low_target): New.
22758	* linux-m68k-low.c (num_regs): Remove.
22759	(m68k_num_regs): Define.
22760	(m68k_regmap): Renamed from regmap, made static.
22761	(m68k_cannot_fetch_register): Renamed from cannot_fetch_register,
22762	made static.
22763	(m68k_cannot_store_register): Renamed from cannot_store_register,
22764	made static.
22765	(the_low_target): New.
22766	* linux-mips-low.c (num_regs): Remove.
22767	(mips_num_regs): Define.
22768	(mips_regmap): Renamed from regmap, made static.
22769	(mips_cannot_fetch_register): Renamed from cannot_fetch_register,
22770	made static.
22771	(mips_cannot_store_register): Renamed from cannot_store_register,
22772	made static.
22773	(the_low_target): New.
22774	* linux-ppc-low.c (num_regs): Remove.
22775	(ppc_num_regs): Define.
22776	(ppc_regmap): Renamed from regmap, made static.
22777	(ppc_cannot_fetch_register): Renamed from cannot_fetch_register,
22778	made static.
22779	(ppc_cannot_store_register): Renamed from cannot_store_register,
22780	made static.
22781	(the_low_target): New.
22782	* linux-s390-low.c (num_regs): Remove.
22783	(s390_num_regs): Define.
22784	(s390_regmap): Renamed from regmap, made static.
22785	(s390_cannot_fetch_register): Renamed from cannot_fetch_register,
22786	made static.
22787	(s390_cannot_store_register): Renamed from cannot_store_register,
22788	made static.
22789	(the_low_target): New.
22790	* linux-sh-low.c (num_regs): Remove.
22791	(sh_num_regs): Define.
22792	(sh_regmap): Renamed from regmap, made static.
22793	(sh_cannot_fetch_register): Renamed from cannot_fetch_register,
22794	made static.
22795	(sh_cannot_store_register): Renamed from cannot_store_register,
22796	made static.
22797	(the_low_target): New.
22798	* linux-x86-64-low.c (x86_64_regmap): Renamed from regmap.
22799	(the_low_target): New.
22800
228012002-04-09  Daniel Jacobowitz  <drow@mvista.com>
22802
22803	* Makefile.in: Add stamp-h target.
22804	* configure.in: Create stamp-h.
22805	* configure: Regenerated.
22806
228072002-04-09  Daniel Jacobowitz  <drow@mvista.com>
22808
22809	* inferiors.c: New file.
22810	* target.c: New file.
22811	* target.h: New file.
22812	* Makefile.in:  Add target.o and inferiors.o.  Update
22813	dependencies.
22814	* linux-low.c (inferior_pid): New static variable,
22815	moved from server.c.
22816	(linux_create_inferior): Renamed from create_inferior.
22817	Call add_inferior.  Return 0 on success instead of a PID.
22818	(linux_attach): Renamed from myattach.
22819	(linux_kill): Renamed from kill_inferior.  Call clear_inferiors ().
22820	(linux_thread_alive): Renamed from mythread_alive.
22821	(linux_wait): Renamed from mywait.  Call clear_inferiors () if the
22822	child dies.
22823	(linux_resume): Renamed from myresume.  Add missing ``return 0''.
22824	(regsets_store_inferior_registers): Correct error message.
22825	Add missing ``return 0''.
22826	(linux_fetch_registers): Renamed from fetch_inferior_registers.
22827	(linux_store_registers): Renamed from store_inferior_registers.
22828	(linux_read_memory): Renamed from read_inferior_memory.
22829	(linux_write_memory): Renamed from write_inferior_memory.
22830	(linux_target_ops): New structure.
22831	(initialize_low): Call set_target_ops ().
22832	* remote-utils.c (unhexify): New function.
22833	(hexify): New function.
22834	(input_interrupt): Send signals to ``signal_pid''.
22835	* server.c (inferior_pid): Remove.
22836	(start_inferior): Update create_inferior call.
22837	(attach_inferior): Call add_inferior.
22838	(handle_query): New function.
22839	(main): Call handle_query for `q' packets.
22840	* server.h: Include "target.h".  Remove obsolete prototypes.
22841	Add prototypes for "inferiors.c", "target.c", hexify, and unhexify.
22842
228432002-04-09  Daniel Jacobowitz  <drow@mvista.com>
22844
22845	* Makefile.in: Add WARN_CFLAGS.  Update configury
22846	dependencies.
22847	* configure.in: Check for <string.h>
22848	* configure: Regenerate.
22849	* config.in: Regenerate.
22850	* gdbreplay.c: Include needed system headers.
22851	(remote_open): Remove strchr prototype.
22852	* linux-low.h: Correct #ifdef to HAVE_LINUX_USRREGS.
22853	* regcache.c (supply_register): Change buf argument to const void *.
22854	(supply_register_by_name): Likewise.
22855	(collect_register): Change buf argument to void *.
22856	(collect_register_by_name): Likewise.
22857	* regcache.h: Add missing prototypes.
22858	* remote-utils.c: Include <arpa/inet.h> for inet_ntoa.
22859	* server.c (handle_query): New function.
22860	(attached): New static variable, moved out of main.
22861	(main): Quiet longjmp clobber warnings.
22862	* server.h: Add ATTR_NORETURN and ATTR_FORMAT.  Update prototypes.
22863	* utils.c (error): Remove NORETURN.
22864	(fatal): Likewise.
22865