the ioctls complained about in bug 93096 as well as one that came up
on the mailing list a few weeks ago.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2982
This required some tricks with casting to maintain Memcheck's silly (ie.
negative) arg checking. The allocator was also changed accordingly. It
should now be able to allocate more than 4GB blocks on 64-bit platforms.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2906
- Added include/x86-linux/ and include/linux/ subdirectories, with Makefile.am
files.
- Overhauled the definitions of kernel types. include/vg_kerneliface.h is now
three files, include/linux/vki.h, include/x86-linux/vki_arch.h, and
include/x86-linux/vki_arch_posixtypes.h. These files separate the
common/Linux and x86/Linux parts cleanly. All code is copied verbatim from
the relevant kernel headers, except that VKI_/vki_ prefixes are added as
necessary to distinguish them from glibc types. (This is done consistently,
unlike previously when some types did not have the prefixes.)
All code is clearly marked to show which particular header file it came from,
and the Linux version used. (I used 2.6.8.1, the most recent stable release,
for all of them.)
A few of the types changed; this is because they changed between the older
versions of Linux and the current 2.6.8.1. I checked that all these changes
were ok with respect to backwards compatibility for our purposes.
- vg_unsafe.h has been removed; we are no longer including any kernel headers,
as we have our own copies for everything. This is because installed kernel
headers are not reliable, and often cause compilation problems. (bug
#92420 is a recent example)
- Removed some no-longer-needed header-presence tests from configure.in.
- Some code in the rest of Valgrind was changed to account for some slight
changes in the names of our VKI_/vki_ kernel constants and types.
- Updated README_MISSING_SYSCALL_OR_IOCTL accordingly.
- Fixed off-by-one error with VKI_GDT_ENTRY_TLS_MAX (merged from stable branch)
The end result is that the kernel types situation should be much clearer, and
similar files can be created relatively easily for other architectures as
necessary.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2884
architectures. Had to recast it as valgrind.h.in; now at configure time the
appropriate #define is set so that the appropriate snippet of assembly code is
chosen. It's done this way rather than with x86/ etc. directories like the
rest of Valgrind, because this header file must stand alone for inclusion by
other programs.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2794
- Moved VG_MAX_REALREGS into x86/ part.
- Tweaked basic types so they're suitable for both 32-bit and 64-bit platforms.
Main change was to change 'Addr' to "unsigned long" which is the same size as
a pointer. Had to make a couple of minor changes to accommodate this.
Also, introduced 'UWord' and 'Word' types which will be necessary for making
code 64-bit clean.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2669
- moved a lot of the baseBlock initialisation into x86/, including all the
VGOFF variables, and all the x86 asm helper functions.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2668
Mackerras's work.
- introduced arch-neutral macros for getting the instruction/frame/stack
pointers.
- renamed ExeContext.eips as ExeContext.ips
- renamed esp/ebp/eip to sp/fp/ip in several related files and arch-neutralised
various comments
- introduced arch-neutral macros for walking the stack
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2663
- Added include/x86/: contains tool_arch.h, Makefile.am, .cvsignore.
- Added coregrind/x86/state.c. Contains some arch-specific code for dealing
with x86 registers -- eg. setting up the baseBlock, loading/saving the whole
register state. It is compiled into coregrind/x86/libarch.a and linked via
${VG_ARCH} with the core.
Relatedly, also added coregrind/x86/{core_arch.h,core_arch_asm.h}.
- Correspondingly abstracted the register state out of ThreadState. This
affected every place that touches registers, and there are a lot of them.
(Eventually all the register touching should be abstracted out in an
arch-neutral way, but not yet; one step at a time.)
- Added some declarations about register loading/saving functions to core.h;
all architectures will have to provide these functions.
- Rejigged the build system so that the arch-specific stuff is all done via
${VG_ARCH}, rather than naming e.g. x86/ directly. Appropriate -I arguments
are used so that all the headers are found, etc.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2656
in C99 but not in C89 except as a GNU extension so it's probably
best not to rely on it.
Patch from Jeroen N. Witmond <jnw@xs4all.nl>.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2617
__attribute((regparm(n))) with REGPARM(n) everywhere. REGPARM() is defined in
vg_skin.h, but will eventually be defined separately for each arch.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2601
are treated as blocking.
This fixes bug #86000 because shmat is no longer treated as blocking
and it is therefore no longer possible for two threads to try and use
the same address for the shared memory segment.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2536
can block (ie F_SETLKW) are treated as blocking.
This resolves the F_SETOWN problem described in bug #85969.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2535