Commit Graph

21 Commits

Author SHA1 Message Date
Ed Schouten
ae824d80f2 Fix warnings found by -Wmising-variable-declarations.
This self-written compiler warning, which is hopefully going to be
committed into LLVM sources soon, warns about potentially missing
`static' keywords, similar to -Wmissing-prototypes.

- bin/pax: Move external declaration of chdname and s_mask into extern.h.
- bin/setfacl: Move setfacl.c-specific stuff out of setfacl.h.
- sbin/mount_fusefs: Remove char *progname; use getprogname().
- others: add `static' where possible.
2012-10-19 05:43:38 +00:00
Marius Strobl
ef6f47c4ae Change lwp to int64_t as thr_pread_long() always uses a 64-bit value
in order to account for LP64 targets when cross-debugging on ILP32,
allowing r224683 to compile on ILP32.
Note that thr_p{read,write}_{long,ptr}() still incorrectly use the size
of the respective types on the host rather than that on the target when
accessing the target address space which still needs to be fixed. This
means that r224683 alone may not be sufficient to solve the problem it's
intended to fix when cross-debugging.

Approved by:	re (hrs)
2011-08-07 15:52:13 +00:00
Marius Strobl
e31fe879a8 The tid member of struct pthread actually is long so read it as such.
Accessing it as an int causes failure on big-endian LP64, i.e. mips64be,
powerpc64 and sparc64.

Reviewed by:	marcel
Approved by:	re (kib)
MFC after:	1 week
2011-08-06 17:48:30 +00:00
Konstantin Belousov
098d0537f2 Extend the td_thrinfo_t to include siginfo for the signal that stopped
the target. Take care of ABI.

Suggested by:	davidxu
MFC after:	2 weeks
2010-07-04 12:08:04 +00:00
Dag-Erling Smørgrav
18860a1cdf Revert r181651, which changed the ABI, and use a temp variable instead.
Suggested by:	attilio
2009-06-09 12:32:10 +00:00
Marcel Moolenaar
03fad2ad5f Allow psaddr_t to be widened by using thr_pread_{int,long,ptr},
where critical. Some places still use ps_pread/ps_pwrite directly,
but only need changed when byte-order comes into the picture.
Also, change th_p in td_event_msg_t from a pointer type to
psaddr_t, so that events also work when psaddr_t is widened.
2008-09-14 16:07:21 +00:00
Marcel Moolenaar
f60a5b31c8 Cleanup for WARNS 6. 2008-08-06 03:14:18 +00:00
Marcel Moolenaar
16b0c20c82 Change the type of psaddr_t from void* to uintptr_t. A pointer
type cannot be made wider to allow ILP32 platforms to target
LP64 platforms.
2008-07-30 00:59:19 +00:00
David Xu
20b94d8035 Use linker set to collection all target operations. 2008-03-22 05:40:44 +00:00
David Xu
ef39743bc3 Fix return value. 2006-05-17 05:14:45 +00:00
David Xu
4f7b0f0ee7 Use ps_linfo to retrieve LWP info, current it is used to retrieve
signal mask and pending signals.
2006-02-07 02:55:34 +00:00
David Xu
83154c48d6 Always clear thread info buffer to zero. 2006-02-06 11:54:19 +00:00
Doug Rabson
8d7681bb7f Add support for XMM registers in GDB for x86 processors that support
SSE (or its successors).

Reviewed by: marcel, davidxu
MFC After: 2 weeks
2005-05-31 09:43:04 +00:00
Philippe Charnier
d36dd0b78e Remove unused variables. 2005-05-20 13:09:49 +00:00
David Xu
787e88a3ac o Code cleanup, eliminate private thread id map, directly
use lwpid as thread id.
 o Export tls pointer.
2005-04-13 04:57:38 +00:00
David Xu
b9da3fd798 Fill traceme and events fields. 2005-04-12 23:33:08 +00:00
David Xu
a80845eab1 Sync with debugger code in libthr. 2005-04-12 03:03:16 +00:00
David Xu
2ec2da8602 Export thread address. 2005-04-05 11:38:30 +00:00
David Xu
e65421ba6f Update debugger code for new libthr. 2005-04-02 01:36:21 +00:00
David Xu
d4ee712657 1. Add missing functions: libthr_dbresume,libthr_dbsuspend.
2. Implement functions: libthr_db_thr_setfpregs, libthr_db_thr_setregs,
   libthr_db_ta_map_id2thr.
3. simplify libthr_db_thr_getfpregs, libthr_db_thr_getgregs.
2004-08-13 06:47:33 +00:00
Marcel Moolenaar
3c1e38ea6e Add rudimentary support and stubs for libthr and libc_r on alpha, amd64,
i386, ia64 and sparc64. Add stubs for alpha, amd64, ia64 and sparc64 for
libpthread.

Restructure the source files to avoid unnecessary use of subdirectories
that also force us to use non-portable compilation flags to deal with
the uncommon compilation requirements (building archive libraries for
linkage into a shared library).

The libpthread support has been copied from the original local and
cleaned-up to make them WARNS=2 clean.
that also force us to use non-portable compilation flags to deal with
the uncommon compilation requirements (building archive libraries for
linkage into a shared library).

The libpthread support has been copied from the original local and
cleaned-up to make them WARNS=2 clean.

Tested on: amd64, i386, ia64
2004-07-18 04:17:15 +00:00