Remove ptid_build
This removes ptid_build in favor of simply calling the ptid_t constructor directly. gdb/ChangeLog 2018-07-03 Tom Tromey <tom@tromey.com> * common/ptid.h (ptid_build): Don't declare. * common/ptid.c (ptid_build): Remove. * aix-thread.c: Update. * bsd-kvm.c: Update. * bsd-uthread.c: Update. * common/agent.c: Update. * common/ptid.c: Update. * common/ptid.h: Update. * corelow.c: Update. * darwin-nat.c: Update. * fbsd-nat.c: Update. * gnu-nat.c: Update. * linux-fork.c: Update. * linux-nat.c: Update. * linux-thread-db.c: Update. * nat/linux-osdata.c: Update. * nat/linux-procfs.c: Update. * nto-procfs.c: Update. * obsd-nat.c: Update. * proc-service.c: Update. * procfs.c: Update. * ravenscar-thread.c: Update. * remote-sim.c: Update. * remote.c: Update. * sol-thread.c: Update. * target.c: Update. * windows-nat.c: Update. gdb/gdbserver/ChangeLog 2018-07-03 Tom Tromey <tom@tromey.com> * linux-low.c: Update. * lynx-low.c: Update. * nto-low.c: Update. * remote-utils.c: Update. * spu-low.c: Update. * thread-db.c: Update. * win32-low.c: Update.
This commit is contained in:
parent
057302ceb3
commit
fd79271bd9
33 changed files with 157 additions and 130 deletions
18
gdb/remote.c
18
gdb/remote.c
|
@ -2955,7 +2955,7 @@ read_ptid (const char *buf, const char **obuf)
|
|||
pp = unpack_varlen_hex (p + 1, &tid);
|
||||
if (obuf)
|
||||
*obuf = pp;
|
||||
return ptid_build (pid, tid, 0);
|
||||
return ptid_t (pid, tid, 0);
|
||||
}
|
||||
|
||||
/* No multi-process. Just a tid. */
|
||||
|
@ -2980,7 +2980,7 @@ read_ptid (const char *buf, const char **obuf)
|
|||
|
||||
if (obuf)
|
||||
*obuf = pp;
|
||||
return ptid_build (pid, tid, 0);
|
||||
return ptid_t (pid, tid, 0);
|
||||
}
|
||||
|
||||
static int
|
||||
|
@ -3972,7 +3972,7 @@ remote_target::static_tracepoint_markers_by_strid (const char *strid)
|
|||
ptid_t
|
||||
remote_target::get_ada_task_ptid (long lwp, long thread)
|
||||
{
|
||||
return ptid_build (ptid_get_pid (inferior_ptid), lwp, 0);
|
||||
return ptid_t (ptid_get_pid (inferior_ptid), lwp, 0);
|
||||
}
|
||||
|
||||
|
||||
|
@ -6037,7 +6037,7 @@ remote_target::append_resumption (char *p, char *endp,
|
|||
ptid_t nptid;
|
||||
|
||||
/* All (-1) threads of process. */
|
||||
nptid = ptid_build (ptid_get_pid (ptid), -1, 0);
|
||||
nptid = ptid_t (ptid_get_pid (ptid), -1, 0);
|
||||
|
||||
p += xsnprintf (p, endp - p, ":");
|
||||
p = write_ptid (p, endp, nptid);
|
||||
|
@ -6615,7 +6615,7 @@ remote_target::remote_stop_ns (ptid_t ptid)
|
|||
|
||||
if (ptid_is_pid (ptid))
|
||||
/* All (-1) threads of process. */
|
||||
nptid = ptid_build (ptid_get_pid (ptid), -1, 0);
|
||||
nptid = ptid_t (ptid_get_pid (ptid), -1, 0);
|
||||
else
|
||||
{
|
||||
/* Small optimization: if we already have a stop reply for
|
||||
|
@ -11321,7 +11321,7 @@ threadalive_test (const char *cmd, int tty)
|
|||
{
|
||||
int sample_thread = SAMPLE_THREAD;
|
||||
int pid = ptid_get_pid (inferior_ptid);
|
||||
ptid_t ptid = ptid_build (pid, sample_thread, 0);
|
||||
ptid_t ptid = ptid_t (pid, sample_thread, 0);
|
||||
|
||||
if (remote_thread_alive (ptid))
|
||||
printf_filtered ("PASS: Thread alive test\n");
|
||||
|
@ -14737,7 +14737,7 @@ stepping is supported by the target. The default is on."),
|
|||
|
||||
/* Take advantage of the fact that the TID field is not used, to tag
|
||||
special ptids with it set to != 0. */
|
||||
magic_null_ptid = ptid_build (42000, -1, 1);
|
||||
not_sent_ptid = ptid_build (42000, -2, 1);
|
||||
any_thread_ptid = ptid_build (42000, 0, 1);
|
||||
magic_null_ptid = ptid_t (42000, -1, 1);
|
||||
not_sent_ptid = ptid_t (42000, -2, 1);
|
||||
any_thread_ptid = ptid_t (42000, 0, 1);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue