]> git.ipfire.org Git - thirdparty/valgrind.git/log
thirdparty/valgrind.git
21 years agoAdd support for POSIIX clocks and timers.
Tom Hughes [Mon, 30 Aug 2004 19:50:02 +0000 (19:50 +0000)] 
Add support for POSIIX clocks and timers.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2630

21 years agoPrint a message if shadow memory cannot be allocated, rather than just
Nicholas Nethercote [Mon, 30 Aug 2004 19:36:42 +0000 (19:36 +0000)] 
Print a message if shadow memory cannot be allocated, rather than just
asserting.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2629

21 years agoAvoid divisions by zero. This fixes bug 78765.
Nicholas Nethercote [Mon, 30 Aug 2004 19:15:12 +0000 (19:15 +0000)] 
Avoid divisions by zero.  This fixes bug 78765.

Also renamed two of the XPt fields so that things are clearer.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2628

21 years agoTry to summarise 2.0.0 -> 2.2.0 changes.
Julian Seward [Mon, 30 Aug 2004 18:15:37 +0000 (18:15 +0000)] 
Try to summarise 2.0.0 -> 2.2.0 changes.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2627

21 years agoDocument 2.1.2 -> 2.2.0 deltas (2.0.0 -> 2.2.0 not yet done)
Julian Seward [Mon, 30 Aug 2004 18:04:42 +0000 (18:04 +0000)] 
Document 2.1.2 -> 2.2.0 deltas (2.0.0 -> 2.2.0 not yet done)

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2626

21 years agoAdd FP conditional move insn (host) and isel rule to generate it.
Julian Seward [Mon, 30 Aug 2004 17:54:18 +0000 (17:54 +0000)] 
Add FP conditional move insn (host) and isel rule to generate it.

git-svn-id: svn://svn.valgrind.org/vex/trunk@222

21 years agoRecognise X.Org servers and treat them the same as XFree86 4.x servers. This
Tom Hughes [Mon, 30 Aug 2004 10:31:21 +0000 (10:31 +0000)] 
Recognise X.Org servers and treat them the same as XFree86 4.x servers. This
avoids warnings from configure about an unknown X server type on recent Linux
distributions that use X.Org instead of XFree86.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2625

21 years agoSwitch to using the newer forms of AC_INIT and AM_INIT_AUTOMAKE so that
Tom Hughes [Sun, 29 Aug 2004 09:46:38 +0000 (09:46 +0000)] 
Switch to using the newer forms of AC_INIT and AM_INIT_AUTOMAKE so that
configure can print the package name correctly.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2624

21 years agoUpdate baseblock layout to deal with FP register tags. Also rearrange
Julian Seward [Fri, 27 Aug 2004 12:01:45 +0000 (12:01 +0000)] 
Update baseblock layout to deal with FP register tags.  Also rearrange
layout a bit so that the fp registers themselves are 8-aligned.

git-svn-id: svn://svn.valgrind.org/vex/trunk@221

21 years agoFront end stuff to support floating point on x86 (guest).
Julian Seward [Fri, 27 Aug 2004 12:00:18 +0000 (12:00 +0000)] 
Front end stuff to support floating point on x86 (guest).

git-svn-id: svn://svn.valgrind.org/vex/trunk@220

21 years agoDeal with PutI/GetI (doesn't do anything interesting with them,
Julian Seward [Fri, 27 Aug 2004 11:58:24 +0000 (11:58 +0000)] 
Deal with PutI/GetI (doesn't do anything interesting with them,
but doesn't bomb out either).

git-svn-id: svn://svn.valgrind.org/vex/trunk@219

21 years agoWhen delivering SIGFPE make sure we patch up si_addr in any siginfo
Tom Hughes [Thu, 26 Aug 2004 23:09:26 +0000 (23:09 +0000)] 
When delivering SIGFPE make sure we patch up si_addr in any siginfo
structure to match the address of the instruction in the client program
which caused the fault.

CCMAIL: 88115-done@bugs.kde.org

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2623

21 years agoFix flags computation for rol/ror instructions in some very obscure
Julian Seward [Thu, 26 Aug 2004 12:30:48 +0000 (12:30 +0000)] 
Fix flags computation for rol/ror instructions in some very obscure
boundary cases (rotate amount > 0 and an exact multiple of the
word size, in bits.).

git-svn-id: svn://svn.valgrind.org/vex/trunk@218

21 years agoInclude the filename in the system call trace for the access syscall.
Tom Hughes [Thu, 26 Aug 2004 12:26:27 +0000 (12:26 +0000)] 
Include the filename in the system call trace for the access syscall.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2622

21 years ago* Enable cmpxchg tests.
Julian Seward [Thu, 26 Aug 2004 11:27:21 +0000 (11:27 +0000)] 
* Enable cmpxchg tests.
* Enable long-running arithmetic test.
* Run the shift/rotate test with all input flag combinations.
  This shows up some incorrect flag results for rotates by
  exact multiples of the word size.

git-svn-id: svn://svn.valgrind.org/vex/trunk@217

21 years agox86->IR->x86: handle byte-sized cmpxchg.
Julian Seward [Thu, 26 Aug 2004 11:24:39 +0000 (11:24 +0000)] 
x86->IR->x86: handle byte-sized cmpxchg.

git-svn-id: svn://svn.valgrind.org/vex/trunk@216

21 years agox86guest_spechelper, calculate_condition(CC_OP_SUBB, CondNBE): mask
Julian Seward [Thu, 26 Aug 2004 01:27:15 +0000 (01:27 +0000)] 
x86guest_spechelper, calculate_condition(CC_OP_SUBB, CondNBE): mask
with the correct value.

git-svn-id: svn://svn.valgrind.org/vex/trunk@215

21 years agoAdd a bit of structure in x86guest_findhelper.
Julian Seward [Thu, 26 Aug 2004 01:25:07 +0000 (01:25 +0000)] 
Add a bit of structure in x86guest_findhelper.

git-svn-id: svn://svn.valgrind.org/vex/trunk@214

21 years agoIf we return from a signal handler to a thread that was waiting to
Tom Hughes [Wed, 25 Aug 2004 18:58:04 +0000 (18:58 +0000)] 
If we return from a signal handler to a thread that was waiting to
rendezvous with another thread before the signal arrived then check
whether the rendezvous is now complete or we may deadlock.

CCMAIL: 77369-done@bugs.kde.org

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2621

21 years agoEven more futzing around with x86-guest eflags helpers.
Julian Seward [Wed, 25 Aug 2004 16:38:30 +0000 (16:38 +0000)] 
Even more futzing around with x86-guest eflags helpers.

git-svn-id: svn://svn.valgrind.org/vex/trunk@213

21 years agoChange things so that stage2's location is controlled by a single variable.
Nicholas Nethercote [Wed, 25 Aug 2004 16:16:56 +0000 (16:16 +0000)] 
Change things so that stage2's location is controlled by a single variable.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2620

21 years agoFix problem with brk(). Thanks to Paull Mackerras for the patch.
Nicholas Nethercote [Wed, 25 Aug 2004 13:43:44 +0000 (13:43 +0000)] 
Fix problem with brk().  Thanks to Paull Mackerras for the patch.
Added a regression test for it.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2619

21 years agoRemove three unnecessary compile-time warnings.
Nicholas Nethercote [Wed, 25 Aug 2004 13:33:17 +0000 (13:33 +0000)] 
Remove three unnecessary compile-time warnings.

Two were trivial.  The one for strncmp is slightly trickier;  you have to be
careful with the signedness of chars when comparing them... but the code
already casts s1 and s2 to (unsigned char*) before comparing them, so it's not
a problem.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2618

21 years agoRemoved comma at the end of an enumerator list - this is allowed
Tom Hughes [Wed, 25 Aug 2004 13:25:30 +0000 (13:25 +0000)] 
Removed comma at the end of an enumerator list - this is allowed
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

21 years agoadd bswapl, and movl $imm8, %cl
Julian Seward [Wed, 25 Aug 2004 13:25:29 +0000 (13:25 +0000)] 
add bswapl, and movl $imm8, %cl

git-svn-id: svn://svn.valgrind.org/vex/trunk@212

21 years agoFix bizarre warning from gcc-3.2.
Julian Seward [Wed, 25 Aug 2004 13:24:44 +0000 (13:24 +0000)] 
Fix bizarre warning from gcc-3.2.

git-svn-id: svn://svn.valgrind.org/vex/trunk@211

21 years agoIntroduce extra paranoia into the instruction selector. Previously,
Julian Seward [Wed, 25 Aug 2004 12:49:22 +0000 (12:49 +0000)] 
Introduce extra paranoia into the instruction selector.  Previously,
iselIntExpr_R et al could compute a value into either a virtual or
real register.  Now, it will only compute a value into a virtual
register, introducing a real->virtual copy if necessary.  Furthermore
this is automatically checked.  This change makes it easier to be
assured that the generated code is correct in the presence of
instructions with fixed register usages.

The downside is that in a few cases, there will be real->virtual reg
copies that didn't exist before.  However, I think reg-alloc can
easily be modified to coalesce these out -- it already coalesces away
virtual-virtual copies.

git-svn-id: svn://svn.valgrind.org/vex/trunk@210

21 years agoFill in some more instructions needed for program startup on Red Hat 8.
Julian Seward [Wed, 25 Aug 2004 12:46:02 +0000 (12:46 +0000)] 
Fill in some more instructions needed for program startup on Red Hat 8.

git-svn-id: svn://svn.valgrind.org/vex/trunk@209

21 years agoConstant folding: do And8/16/32(t,t) ==> t, for some IRTemp t
Julian Seward [Wed, 25 Aug 2004 12:45:13 +0000 (12:45 +0000)] 
Constant folding: do And8/16/32(t,t) ==> t, for some IRTemp t

git-svn-id: svn://svn.valgrind.org/vex/trunk@208

21 years agoFix symlinking -- the old code worked, but worked for the wrong reason; the
Nicholas Nethercote [Wed, 25 Aug 2004 11:57:21 +0000 (11:57 +0000)] 
Fix symlinking -- the old code worked, but worked for the wrong reason;  the
bit before "$(subdir)" has to specify the path from .in_place/ to the root.
It just so happened that $(top_builddir) was the same for all directories at
the same level in the hierarchy as .in_place/ (ie. one deep).

(I haven't bothered changing it in all the tool Makefile.am files, because I'll
do that when I factor out all their common bits into a single file, be it
before or after 2.2.0 is released.)

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2616

21 years agoMinor fixups:
Nicholas Nethercote [Wed, 25 Aug 2004 11:50:46 +0000 (11:50 +0000)] 
Minor fixups:
- introduce $(inplacedir) like everywhere else
- valgrind.spec doesn't need to be included in "make dist", because it gets
  built from valgrind.spec.in at configure-time.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2615

21 years agoPutting "dist_" in front of a "_DATA" variable means it is included in "make
Nicholas Nethercote [Wed, 25 Aug 2004 11:40:07 +0000 (11:40 +0000)] 
Putting "dist_" in front of a "_DATA" variable means it is included in "make
dist".  This avoids the need to put it in "EXTRA_DIST", and saves a few lines
in all the docs Makefile.am files.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2614

21 years agox86 front end: fast-track yet another SUBL case (SUBL then CondB)
Julian Seward [Tue, 24 Aug 2004 23:50:56 +0000 (23:50 +0000)] 
x86 front end: fast-track yet another SUBL case (SUBL then CondB)

git-svn-id: svn://svn.valgrind.org/vex/trunk@207

21 years agoFix bug in assembly of CMov32(reg,reg) in which the regs were handled
Julian Seward [Tue, 24 Aug 2004 23:34:39 +0000 (23:34 +0000)] 
Fix bug in assembly of CMov32(reg,reg) in which the regs were handled
the wrong way round.  This was causing test/test-i386.c to fail on
shifts of zero.  Now that test works completely.

git-svn-id: svn://svn.valgrind.org/vex/trunk@206

21 years agoOnly check whether linux/mii.h can be processed so that we don't
Tom Hughes [Tue, 24 Aug 2004 23:09:07 +0000 (23:09 +0000)] 
Only check whether linux/mii.h can be processed so that we don't
generate ugly warnings by trying to compile it.

Patch from Eric Estievenart <eric.estievenart@free.fr>

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2613

21 years agoComment only change: note an example where better code could have
Julian Seward [Tue, 24 Aug 2004 22:45:30 +0000 (22:45 +0000)] 
Comment only change: note an example where better code could have
been generated (from md5sum iirc)

git-svn-id: svn://svn.valgrind.org/vex/trunk@205

21 years agoGet rid of executables inadvertantly commited in rev 203.
Julian Seward [Tue, 24 Aug 2004 22:44:36 +0000 (22:44 +0000)] 
Get rid of executables inadvertantly commited in rev 203.

git-svn-id: svn://svn.valgrind.org/vex/trunk@204

21 years agoAdd a modified version of the QEMU test program. This commit
Julian Seward [Tue, 24 Aug 2004 22:43:26 +0000 (22:43 +0000)] 
Add a modified version of the QEMU test program.  This commit
erroneously includes binaries; the next will remove them.

git-svn-id: svn://svn.valgrind.org/vex/trunk@203

21 years agoRedo x86 flag stuff a bit. Primarily, change the thunk arg meanings
Julian Seward [Tue, 24 Aug 2004 15:10:38 +0000 (15:10 +0000)] 
Redo x86 flag stuff a bit.  Primarily, change the thunk arg meanings
for ADD and SUB from holding one operand and the result to just
holding both operands.  This allows more efficient code to be
generated for specialised calls to calculate_condition().

Do some tuning, without a lot of success.

Fix recently introduced bug causing some mis-computation of
the overflow flag.

With the optimiser on, the flag stuff now fails for shifts of
zero.  I have yet to track this down.

git-svn-id: svn://svn.valgrind.org/vex/trunk@202

21 years agoAdd a reassuring warnings about the linux/mii.h warning.
Nicholas Nethercote [Tue, 24 Aug 2004 14:38:53 +0000 (14:38 +0000)] 
Add a reassuring warnings about the linux/mii.h warning.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2612

21 years agoUpdate for filename change.
Nicholas Nethercote [Tue, 24 Aug 2004 13:56:54 +0000 (13:56 +0000)] 
Update for filename change.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2611

21 years agoPretty-up the flag-calculating macros. Whitespace only change.
Julian Seward [Tue, 24 Aug 2004 01:46:34 +0000 (01:46 +0000)] 
Pretty-up the flag-calculating macros.  Whitespace only change.

git-svn-id: svn://svn.valgrind.org/vex/trunk@201

21 years agoFast-case a couple more flag/thunk conditions.
Julian Seward [Tue, 24 Aug 2004 01:16:01 +0000 (01:16 +0000)] 
Fast-case a couple more flag/thunk conditions.

git-svn-id: svn://svn.valgrind.org/vex/trunk@200

21 years agowibble
Julian Seward [Tue, 24 Aug 2004 00:43:54 +0000 (00:43 +0000)] 
wibble

git-svn-id: svn://svn.valgrind.org/vex/trunk@199

21 years agoSet bb size back to 20.
Julian Seward [Tue, 24 Aug 2004 00:38:02 +0000 (00:38 +0000)] 
Set bb size back to 20.

git-svn-id: svn://svn.valgrind.org/vex/trunk@198

21 years ago* setHints_Expr: remember to recurse the entire tree!
Julian Seward [Tue, 24 Aug 2004 00:37:04 +0000 (00:37 +0000)] 
* setHints_Expr: remember to recurse the entire tree!
  Not doing so leads to nasty bugs in which the tree-builder
  incorrectly reorders Gets and Puts.

* related: remember PutI is a kind of Put too.

git-svn-id: svn://svn.valgrind.org/vex/trunk@197

21 years agoFix error in scheme for assembly Xin_Set32 when the dest is %esi/%edi
Julian Seward [Tue, 24 Aug 2004 00:24:56 +0000 (00:24 +0000)] 
Fix error in scheme for assembly Xin_Set32 when the dest is %esi/%edi
and so a swap reg has to be used instead.  The error was that the dest
was being initially assigned to zero, whereas it should have been
%eax that was initially assigned zero.

git-svn-id: svn://svn.valgrind.org/vex/trunk@196

21 years agoThe size passed to VG_(st_mkfloat) should be in bytes, not bits.
Tom Hughes [Mon, 23 Aug 2004 23:18:57 +0000 (23:18 +0000)] 
The size passed to VG_(st_mkfloat) should be in bytes, not bits.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2610

21 years agoBetter printing of raw bb data.
Julian Seward [Mon, 23 Aug 2004 22:57:45 +0000 (22:57 +0000)] 
Better printing of raw bb data.

git-svn-id: svn://svn.valgrind.org/vex/trunk@195

21 years agoAdded code to decode a number of additional negative type numbers
Tom Hughes [Mon, 23 Aug 2004 22:29:31 +0000 (22:29 +0000)] 
Added code to decode a number of additional negative type numbers
in STABS debug information based on the stabs specification at:

  http://sources.redhat.com/cygwin/stabs.html

CCMAIL: 85811-done@bugs.kde.org

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2609

21 years agoPrevent a memcpy of zero bytes from complaining if one or both of the
Tom Hughes [Mon, 23 Aug 2004 18:39:09 +0000 (18:39 +0000)] 
Prevent a memcpy of zero bytes from complaining if one or both of the
pointers given as arguments is uninitialised.

CCMAIL: 86989-done@bugs.kde.org

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2608

21 years agoAdd explanatory comment.
Robert Walsh [Mon, 23 Aug 2004 18:15:12 +0000 (18:15 +0000)] 
Add explanatory comment.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2607

21 years agoFix to allow 32-bit Valgrind to run on AMD64 boxes. Note: this does
Robert Walsh [Mon, 23 Aug 2004 18:13:16 +0000 (18:13 +0000)] 
Fix to allow 32-bit Valgrind to run on AMD64 boxes.  Note: this does
NOT allow Valgrind to work with 64-bit executables - only with 32-bit
executables on an AMD64 box.

VG_(valgrind_end) now has a slightly different meaning to all the other
VG_(*_end) vars -- ie. it names the last byte, whereas the others go
one byte past the end.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2606

21 years agoDon't version the sem_xxx symbols that have more than one version in
Tom Hughes [Mon, 23 Aug 2004 18:05:51 +0000 (18:05 +0000)] 
Don't version the sem_xxx symbols that have more than one version in
glibc - it doesn't matter for valgrind as we only have one version and
by not versioning them we work no matter what version is asked for.

CCMAIL: 86289-done@bugs.kde.org

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2605

21 years agoHere's a couple more I missed in the last commit.
Nicholas Nethercote [Mon, 23 Aug 2004 16:39:42 +0000 (16:39 +0000)] 
Here's a couple more I missed in the last commit.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2604

21 years agoUse SYSNO and res, etc, instead of tst->m_eax in a few places to make things
Nicholas Nethercote [Mon, 23 Aug 2004 16:36:09 +0000 (16:36 +0000)] 
Use SYSNO and res, etc, instead of tst->m_eax in a few places to make things
less x86-specific.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2603

21 years agoAllow iropt to pass helper function calls back to the front end
Julian Seward [Mon, 23 Aug 2004 16:16:08 +0000 (16:16 +0000)] 
Allow iropt to pass helper function calls back to the front end
in the hope of getting specialised versions thereof.

Use this mechanism to greatly improve handling of condition
codes.  Various ensuing small changes.

git-svn-id: svn://svn.valgrind.org/vex/trunk@194

21 years agoMakefile.am minor correction
Nicholas Nethercote [Mon, 23 Aug 2004 15:42:21 +0000 (15:42 +0000)] 
Makefile.am minor correction

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2602

21 years agoSmall step in factoring out arch-specific code: replace
Nicholas Nethercote [Mon, 23 Aug 2004 15:06:23 +0000 (15:06 +0000)] 
Small step in factoring out arch-specific code:  replace
__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

21 years agoTweak configure.in in preparation for arch and OS ports -- we now have
Nicholas Nethercote [Mon, 23 Aug 2004 14:54:40 +0000 (14:54 +0000)] 
Tweak configure.in in preparation for arch and OS ports -- we now have
variables VG_ARCH, VG_OS and VG_PLATFORM (which equals ${VG_ARCH}-${VG_OS}).
Also added a check for the platform (arch/OS) combination.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2600

21 years agoRemoving the example tool 'example' -- it's almost identical to Nulgrind,
Nicholas Nethercote [Mon, 23 Aug 2004 14:15:29 +0000 (14:15 +0000)] 
Removing the example tool 'example' -- it's almost identical to Nulgrind,
except it doesn't actually get built and so ex_main.c and the Makefile.am tend
to get out of date.  Changed the docs to refer to Nulgrind as the example tool
for if you start writing a new one.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2599

21 years agoMake some changes to Nulgrind -- it looks like Jeremy made some changes to it
Nicholas Nethercote [Mon, 23 Aug 2004 14:10:36 +0000 (14:10 +0000)] 
Make some changes to Nulgrind -- it looks like Jeremy made some changes to it
as part of FV, but then later these changes become unnecessary.  Anyway, it now
looks more like the other tools again.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2598

21 years agoRemove a bunch of unnecessary -DVG_LIBDIR="\"$(libdir)"\" arguments in
Nicholas Nethercote [Mon, 23 Aug 2004 14:02:03 +0000 (14:02 +0000)] 
Remove a bunch of unnecessary -DVG_LIBDIR="\"$(libdir)"\" arguments in
Makefile.am files.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2597

21 years agoFix bug, courtesy of Paul Mackerras: when giving find_map_space an address
Nicholas Nethercote [Mon, 23 Aug 2004 09:28:37 +0000 (09:28 +0000)] 
Fix bug, courtesy of Paul Mackerras: when giving find_map_space an address
lower than that of any existing segment, it got it wrong due to the confusing
SkipList API.  I wonder how many more bugs like that there are...?

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2596

21 years agoMore fixes for the cancellation wrappers in libpthread - if looking
Tom Hughes [Sun, 22 Aug 2004 22:56:25 +0000 (22:56 +0000)] 
More fixes for the cancellation wrappers in libpthread - if looking
for the original function with RTLD_NEXT doesn't work then try looking
for the __libc_ version of the function the RTLD_DEFAULT instead.

The reason for this is that, contrary to the dlsym documentation, it
seems that RTLD_NEXT doesn't always seem to find the definition that
would have been used if it weren't for the override. This is particularly
common wihen libpthread is pulled in implicitly by a dependency from
another library.

This should hopefully fix bug #85658.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2595

21 years agoWhitespace-only changes for the tree-builder.
Julian Seward [Sun, 22 Aug 2004 09:48:08 +0000 (09:48 +0000)] 
Whitespace-only changes for the tree-builder.

git-svn-id: svn://svn.valgrind.org/vex/trunk@193

21 years agoFirst pass at a tree-builder algorithm.
Julian Seward [Sun, 22 Aug 2004 02:38:11 +0000 (02:38 +0000)] 
First pass at a tree-builder algorithm.

git-svn-id: svn://svn.valgrind.org/vex/trunk@192

21 years agoFill in some missing cases in the assembler.
Julian Seward [Sun, 22 Aug 2004 02:37:25 +0000 (02:37 +0000)] 
Fill in some missing cases in the assembler.

git-svn-id: svn://svn.valgrind.org/vex/trunk@191

21 years agoAdd support for a --time-stamp option that causes each message output
Tom Hughes [Sat, 21 Aug 2004 11:10:44 +0000 (11:10 +0000)] 
Add support for a --time-stamp option that causes each message output
by valgrind to include a time stamp. This fixes bug #70587.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2594

21 years agoAdd (unused) pattern for generating rotate insns, as an example.
Julian Seward [Fri, 20 Aug 2004 23:39:55 +0000 (23:39 +0000)] 
Add (unused) pattern for generating rotate insns, as an example.

git-svn-id: svn://svn.valgrind.org/vex/trunk@190

21 years agoHandle NOT (Grp3(M) case 2)
Julian Seward [Fri, 20 Aug 2004 23:38:07 +0000 (23:38 +0000)] 
Handle NOT (Grp3(M) case 2)

git-svn-id: svn://svn.valgrind.org/vex/trunk@189

21 years ago* constant fold Shr32
Julian Seward [Fri, 20 Aug 2004 01:01:04 +0000 (01:01 +0000)] 
* constant fold Shr32
* fix up types on folding rules for Shr32/Shl32/Sar32

git-svn-id: svn://svn.valgrind.org/vex/trunk@188

21 years ago* iropt: constant-fold Sar32, and be more careful with Shl32
Julian Seward [Fri, 20 Aug 2004 00:28:13 +0000 (00:28 +0000)] 
* iropt: constant-fold Sar32, and be more careful with Shl32
* x86-host: add a case to the assembler for 'mul'

git-svn-id: svn://svn.valgrind.org/vex/trunk@187

21 years agoRedundant-Put removal.
Julian Seward [Fri, 20 Aug 2004 00:11:12 +0000 (00:11 +0000)] 
Redundant-Put removal.

git-svn-id: svn://svn.valgrind.org/vex/trunk@186

21 years agoWhen doing debug stops (--stop-after), print bb orig bytes in a form
Julian Seward [Fri, 20 Aug 2004 00:10:04 +0000 (00:10 +0000)] 
When doing debug stops (--stop-after), print bb orig bytes in a form
readable by the simple test driver (test_main.c).

git-svn-id: svn://svn.valgrind.org/vex/trunk@185

21 years agoHeader changes for Bit-typed constants. Really this should have
Julian Seward [Fri, 20 Aug 2004 00:09:03 +0000 (00:09 +0000)] 
Header changes for Bit-typed constants.  Really this should have
been committed as part of rev 183.

git-svn-id: svn://svn.valgrind.org/vex/trunk@184

21 years agoAllow constant folding to apply to IRStmt_Exit.
Julian Seward [Thu, 19 Aug 2004 17:58:45 +0000 (17:58 +0000)] 
Allow constant folding to apply to IRStmt_Exit.

git-svn-id: svn://svn.valgrind.org/vex/trunk@183

21 years agoMore folding rules, and some debug printing fixes.
Julian Seward [Thu, 19 Aug 2004 17:16:52 +0000 (17:16 +0000)] 
More folding rules, and some debug printing fixes.

git-svn-id: svn://svn.valgrind.org/vex/trunk@182

21 years agoiselExpr64: Handle 64-bit literals
Julian Seward [Thu, 19 Aug 2004 17:15:49 +0000 (17:15 +0000)] 
iselExpr64: Handle 64-bit literals

git-svn-id: svn://svn.valgrind.org/vex/trunk@181

21 years agoFix reg-alloc bug exposed by more aggressive code generation
Julian Seward [Thu, 19 Aug 2004 16:44:45 +0000 (16:44 +0000)] 
Fix reg-alloc bug exposed by more aggressive code generation
enabled by recent iropt hacking.

When looking for a real-reg to house a virtual reg, reg-alloc
looks around for (v,r) pairs in which v is already dead, and
so r can be re-used for a new virtual reg.  However, it would
be too aggressive in this, and use v even if v went dead
immediately before the current insn, which means v could still
be read by the current insn.  This change requires that v go
dead before the insn prior to this one, so that we are
guaranteed v is not used in this insn.

This commit message is way longer than the actual bug fix :-)

git-svn-id: svn://svn.valgrind.org/vex/trunk@180

21 years agoIncrease size of spill area from 96 bytes to 400 bytes.
Julian Seward [Thu, 19 Aug 2004 10:50:41 +0000 (10:50 +0000)] 
Increase size of spill area from 96 bytes to 400 bytes.

git-svn-id: svn://svn.valgrind.org/vex/trunk@179

21 years agoAdd redundant-GET elimination.
Julian Seward [Thu, 19 Aug 2004 10:49:10 +0000 (10:49 +0000)] 
Add redundant-GET elimination.

git-svn-id: svn://svn.valgrind.org/vex/trunk@178

21 years agoRename VGOFF_(tls) to VGOFF_(tls_ptr) to make it clear it's not the same as
Nicholas Nethercote [Wed, 18 Aug 2004 23:11:45 +0000 (23:11 +0000)] 
Rename VGOFF_(tls) to VGOFF_(tls_ptr) to make it clear it's not the same as
ThreadState.tls.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2593

21 years agoRemove 3 identical and self-admittedly spurious assertions.
Nicholas Nethercote [Wed, 18 Aug 2004 22:26:01 +0000 (22:26 +0000)] 
Remove 3 identical and self-admittedly spurious assertions.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2592

21 years agoTeach iropt to do dead code elimination.
Julian Seward [Wed, 18 Aug 2004 16:54:52 +0000 (16:54 +0000)] 
Teach iropt to do dead code elimination.

git-svn-id: svn://svn.valgrind.org/vex/trunk@177

21 years agoCleaned up the syscall wrappers a bit:
Nicholas Nethercote [Wed, 18 Aug 2004 14:37:17 +0000 (14:37 +0000)] 
Cleaned up the syscall wrappers a bit:
- corrected a few mistakes, eg. when printing them out, in prototypes
- made printing of "%p(%s)" args consistent
- removed 'sizeof_struct_user_fpxregs_struct' from PRE(ptrace)/POST(ptrace)
- allowing for the two different versions of open()

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2591

21 years agoConstant and copy propagation, and start of constant folding.
Julian Seward [Wed, 18 Aug 2004 13:59:33 +0000 (13:59 +0000)] 
Constant and copy propagation, and start of constant folding.

git-svn-id: svn://svn.valgrind.org/vex/trunk@176

21 years agoNew header priv/ir/iropt.h
Julian Seward [Wed, 18 Aug 2004 13:58:59 +0000 (13:58 +0000)] 
New header priv/ir/iropt.h

git-svn-id: svn://svn.valgrind.org/vex/trunk@175

21 years agoMinor rejigging of includes to help compilation on Debian systems.
Tom Hughes [Wed, 18 Aug 2004 08:11:34 +0000 (08:11 +0000)] 
Minor rejigging of includes to help compilation on Debian systems.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2590

21 years agoGenerate 'test' rather than 'and' for some 32-to-1 casts.
Julian Seward [Wed, 18 Aug 2004 00:28:48 +0000 (00:28 +0000)] 
Generate 'test' rather than 'and' for some 32-to-1 casts.

git-svn-id: svn://svn.valgrind.org/vex/trunk@174

21 years agoiropt: implement flattening (into SSA form). This caused various
Julian Seward [Tue, 17 Aug 2004 23:59:23 +0000 (23:59 +0000)] 
iropt: implement flattening (into SSA form).  This caused various
primops to become exposed when previously they were treated as part
of a pattern, hence the changes to host-x86/*.c to handle them.

git-svn-id: svn://svn.valgrind.org/vex/trunk@173

21 years agoConnect no-op iropt to the driver logic.
Julian Seward [Tue, 17 Aug 2004 13:52:58 +0000 (13:52 +0000)] 
Connect no-op iropt to the driver logic.

git-svn-id: svn://svn.valgrind.org/vex/trunk@172

21 years agoMake a start on the intermediate-representation optimiser.
Julian Seward [Tue, 17 Aug 2004 13:31:55 +0000 (13:31 +0000)] 
Make a start on the intermediate-representation optimiser.

git-svn-id: svn://svn.valgrind.org/vex/trunk@171

21 years agogetgroups can't block
Nicholas Nethercote [Tue, 17 Aug 2004 13:26:52 +0000 (13:26 +0000)] 
getgroups can't block

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2589

21 years agoIncrease size of temp area to 100k to handle some really useless
Julian Seward [Mon, 16 Aug 2004 21:59:34 +0000 (21:59 +0000)] 
Increase size of temp area to 100k to handle some really useless
code generation of long BBs.

git-svn-id: svn://svn.valgrind.org/vex/trunk@170

21 years agoFix stupid bug caused by introduction of new FP state.
Julian Seward [Mon, 16 Aug 2004 21:40:49 +0000 (21:40 +0000)] 
Fix stupid bug caused by introduction of new FP state.

git-svn-id: svn://svn.valgrind.org/vex/trunk@169

21 years agoAdd support for the parallel port ioctls.
Tom Hughes [Mon, 16 Aug 2004 19:46:55 +0000 (19:46 +0000)] 
Add support for the parallel port ioctls.

CCMAIL: 86407-done@bugs.kde.org

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2588

21 years agoTreat a thread which is waiting to be reaped (ie one with a status
Tom Hughes [Sun, 15 Aug 2004 14:34:02 +0000 (14:34 +0000)] 
Treat a thread which is waiting to be reaped (ie one with a status
of VgTs_WaitJoiner) as non-existent for the purposes of cancellation.

This ensures that pthread_cancel returns ESRCH instead of trying to
cancel the thread, which would lead to the thread cleanup code being
run twice.

CCMAIL: 86730-done@bugs.kde.org

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2587

21 years agoBack out yesterday's change to the symbol versioning in the pthread
Tom Hughes [Sun, 15 Aug 2004 14:11:12 +0000 (14:11 +0000)] 
Back out yesterday's change to the symbol versioning in the pthread
library - it seems that I misunderstood hom the versioning works and
a system looking for a GLIBC_PRIVATE version of the clock routines
would not find the GLIB_2.2.3 one even with the inheritance. It only
seemed to be working on glibc 2.3 systems because of the version
overrides in the source code, but it failed on glibc 2.2.5 systems.

The new approach is to explicity create two versions of the routines
in question, one with a version of GLIBC_2.2.3 and one with a version
of GLIBC_PRIVATE instead. This has been tested on six different systems
and appears to work everywhere.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2586

21 years agoMore FPU stuff.
Julian Seward [Sun, 15 Aug 2004 03:12:41 +0000 (03:12 +0000)] 
More FPU stuff.

git-svn-id: svn://svn.valgrind.org/vex/trunk@168