365 Commits

Author SHA1 Message Date
Julian Seward
5679a22410 Update copyright dates ("200X-2007" --> "200X-2008").
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7398
2008-02-11 11:34:59 +00:00
Tom Hughes
3f4849d83f Add const qualifiers to appropriate arguments of OSet routines.
Patch from Bart Van Assche <bart.vanassche@gmail.com>.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7308
2007-12-30 12:28:26 +00:00
Nicholas Nethercote
d6b40a390d Fixed up the log file mess throughout, including the docs. This killed
--log-file-qualifier and --log-file-exactly.

Updated NEWS some in preparation for 3.3.0.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7202
2007-11-23 01:41:32 +00:00
Julian Seward
9101880b1f Update documents in preparation for 3.3.0, and restructure them
somewhat to move less relevant material out of the way to some extent.
The main changes are:

* Update date and version info

* Mention other tools in the quick-start guide

* Document --child-silent-after-fork

* Rearrange order of sections in the Valgrind Core chapter, to move
  advanced stuff (client requests) to the end, and compact stuff
  relevant to the majority of users towards the front

* Move MPI debugging stuff from the Core manual (a nonsensical place
  for it) to the Memcheck chapter

* Update the manual's introductory chapter a bit

* Connect up new tech docs summary page, and disconnect old and
  very out of date valgrind/memcheck tech docs

* Add section tags to the Cachegrind manual, to stop xsltproc
  complaining about their absence



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7199
2007-11-22 01:21:56 +00:00
Julian Seward
5e290312a0 Track vex r1793: make all tools able to handle the new IR memory bus
event statement (Ist_MBE).



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@7119
2007-11-09 23:06:35 +00:00
Nicholas Nethercote
7cb817e078 Fix various format string errors, courtesy of Florian Krohm.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@6902
2007-09-23 00:51:24 +00:00
Nicholas Nethercote
c7a4bb81a5 Add a section to the cachegrind manual suggesting how to act on the results.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@6853
2007-09-17 22:28:21 +00:00
Nicholas Nethercote
5771d4fcc6 Add section on how to use Cachegrind's results.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@6852
2007-09-17 22:19:01 +00:00
Nicholas Nethercote
8cdbb6e02f minor tweak
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@6851
2007-09-17 22:01:14 +00:00
Nicholas Nethercote
0974a299f5 Split the OSet interface into two parts: "OSetGen_", which is the existing
interface and provides full power;  and "OSetWord_", which is an
easier-to-use interface for if you just want to store words.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@6841
2007-09-17 05:30:48 +00:00
Nicholas Nethercote
f4e68cda86 Add directory-reading of debug info to cachegrind.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@6839
2007-09-17 00:41:07 +00:00
Julian Seward
32a6fb4fec Get rid of VG_(getcwd) and replace it with a pair of functions,
VG_(record_startup_wd) which records the working directory at startup,
and VG_(get_startup_wd) which later tells you what value was recorded.
This works because all uses of VG_(getcwd) serve only to record the
directory at process start anyway.  The motivation is that AIX does
not support sys_getcwd directly, so it's easier for the launcher to
ship in the required value using an environment variable.  On Linux
sys_getcwd is used as before.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@6764
2007-07-09 23:13:07 +00:00
Julian Seward
466b2ab809 Apparently 'index' shadows a global decl on some targets; therefore rename.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@6759
2007-06-05 20:48:54 +00:00
Julian Seward
b91b51b42b Merge (from 3.2 branch) r6743 (Edit the manual to bring it up to date
and make some of the wording a bit more professional sounding.)



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@6745
2007-05-23 21:58:33 +00:00
Julian Seward
e16417ddf7 Add branch-misprediction profiling to Cachegrind. When the (new) flag
--branch-sim=yes is specified, Cachegrind simulates a simple indirect
branch predictor and a conditional branch predictor.  The latter
considers both the branch instruction's address and the behaviour of
the last few conditional branches.  Return stack prediction is not
modelled.

The new counted events are: conditional branches (Bc), mispredicted
conditional branches (Bcm), indirect branches (Bi) and mispredicted
indirect branches (Bim).  Postprocessing tools (cg_annotate, cg_merge)
handle the new events as you would expect.  Note that branch
simulation is not enabled by default as it gives a 20%-25% slowdown,
so you need to ask for it explicitly using --branch-sim=yes.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@6733
2007-05-08 09:20:25 +00:00
Nicholas Nethercote
802b418634 Fix some copyright notices:
- extend some to 2007
- use njn@valgrind.org instead of njn25@cam.ac.uk
- use "tool" instead of "skin"


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@6703
2007-04-15 22:15:57 +00:00
Nicholas Nethercote
9dae2dbbdf Explicitly zero CCs. It's already being done by VG_(OSet_AllocNode), but
that's more by chance than design.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@6691
2007-04-02 03:11:41 +00:00
Julian Seward
b7302d9258 Get rid of the type XArrayStrings in m_clientstate and use new generic
equivalents in module m_xarray instead.  A suprisingly pervasive
change.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@6616
2007-02-25 15:08:24 +00:00
Julian Seward
db5018c18d Add cg_merge, a program for merging (adding) cachegrind output files,
and associated documentation.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@6574
2007-02-08 11:31:03 +00:00
Julian Seward
5748ebe527 Add a new flag --cachegrind-log-file to cg_annotate, which tells it
precisely the name of the profile data file it should use (instead of
assuming cachegrind.out.<pid> where <pid> is specified by the --<pid>
flag).  The old mechanism is still supported though.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@6573
2007-02-08 06:47:19 +00:00
Julian Seward
1e55d37448 * Add new flag --cachegrind-out-file to specify the output file
basename to be something other than "cachegrind.out".

* Observe the core-supplied --log-file-qualifier, if specified,
  in creation of output file names.

* To make the above work, move most of the stuff in cg_pre_clo_init
  into cg_post_clo_init, so that the core's determination of the
  log file qualifier, if any, is done by the time cachegrind comes
  to process its arguments.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@6572
2007-02-07 19:55:30 +00:00
Nicholas Nethercote
93d2f6d24b Add missing item.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@6542
2007-01-22 03:21:27 +00:00
Julian Seward
172505c978 Update copyright dates.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@6488
2007-01-08 06:01:59 +00:00
Julian Seward
1083ded7e2 Non-functional commit: track IR renaming in vex r1689.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@6416
2006-12-24 02:24:11 +00:00
Julian Seward
62d6f5c373 Fix 'make html-docs' and 'make print-docs'.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@6389
2006-12-10 02:59:16 +00:00
Nicholas Nethercote
2c3a6359bb Use the newly-added dopyIRBBExceptStmts() in tools.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@6372
2006-11-25 22:38:11 +00:00
Josef Weidendorfer
cbe9835fa9 Cachegrind/Callgrind: Fix cache parameter detection
On Intel processors, CPUIDs cache parameter code 0x49 is
reused both for L2 and L3 parameters.
Thanks to Ulrich Drepper.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@6369
2006-11-23 13:04:30 +00:00
Nicholas Nethercote
38011f7248 Fix obscure bug in cache simulation, found by Ulrich Drepper.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@6365
2006-11-22 11:38:07 +00:00
Nicholas Nethercote
49597e705c Update for recent removal of Cachegrind tech docs.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@6336
2006-10-21 23:18:57 +00:00
Nicholas Nethercote
df0cb32d94 Link to dissertation with a proper link.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@6334
2006-10-21 23:00:59 +00:00
Nicholas Nethercote
525ca8b1ee Removed the file format description from cg_annotate.in, because it's in the
Cachegrind docs.

Removed the Cachegrind tech docs, because they're so out of date to be
useless.  My PhD dissertation gives a much better description of how
Cachegrind works.  (I mentioned this in the Cachegrind user manual.)  The
only still-useful part of Cachegrind's tech docs, the output file format
description, I moved into the Cachegrind user manual.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@6332
2006-10-21 22:22:59 +00:00
Nicholas Nethercote
f280fb47d2 - Update comments about Cachegrind file format.
- Be slightly more strict in accepting Cachegrind input files.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@6330
2006-10-21 18:22:35 +00:00
Julian Seward
12ef34f623 Track SysRes change.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@6294
2006-10-17 02:15:17 +00:00
Julian Seward
713b2d46c0 Merge r6086:
Makefile.am changes for AIX5.  Almost all boilerplate stuff fitting in
with the existing factorisation scheme.  The only change of interest
is that configure.in now generates automake symbols of name
VGP_platform and VGO_os, whereas previously it just made VG_platform
which was a bit inconsistent with the VGP/VGO/VGA scheme used in C
code.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@6242
2006-10-17 00:56:43 +00:00
Julian Seward
f4560d1332 Move functions which deal with bad command line options from m_main
into m_options.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@6233
2006-10-15 01:25:13 +00:00
Julian Seward
ae8215b3ac Create a new module, m_vki, and move all knowledge about the kernel
interface, except for the syscall numbers, into that.  Mostly this
means moving include/vki-*.h to include/vki/vki-*.h.

include/pub_tool_basics.h previously dragged in the entire kernel
interface.  I've done away with that, so that modules which need to
see the kernel interface now have to include pub_{core,tool}_vki.h
explicitly.  This is why there are many modified .c files -- they have
all acquired an extra #include line.

This certainly breaks all platforms except x86.  Will fix shortly.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@6225
2006-10-14 19:26:10 +00:00
Josef Weidendorfer
fd997073d2 Cachegrind: Update cache parameter detection
This updates the automatic detection of cache parameters
for x86 and amd64 according to revision 21 of
Intels x86 Architecture Software Developer Manual, Volume 2a.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@6211
2006-10-12 14:23:38 +00:00
Julian Seward
8ab1a1392d Print the same text as micro_ops_warn on x86; doing otherwise defeats the
stderr filter for said text and so makes the test fail on Pentium-4's in
64-bit mode.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@5995
2006-08-01 17:26:38 +00:00
Julian Seward
ad67fd79fe Update copyright dates.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@5954
2006-06-05 23:21:15 +00:00
Nicholas Nethercote
8e42c9224c - Fix indentation in one section of Cachegrind
- In the same section, use VG_(percentify) to avoid overflow when computing
  information for -v printing.


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@5857
2006-04-18 22:34:48 +00:00
Julian Seward
72341b358b Index the BB_info table by redirected guest address, not
non-redirected guest address.  This is a small but significant change
needed to make function wrapping work.  The problem is that with
function wrapping two different translations are associated with the
non-redirected address (of a wrapped function entry point), and so
cachegrind asserts.  Whereas the redirected guest addresses reflect
the reality of only one translation associated with each address.  So
use them instead.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@5582
2006-01-22 01:12:51 +00:00
Julian Seward
15519cf976 Test to check that cachegrind's BB_info management system isn't
confused by function wrapping.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@5579
2006-01-22 01:08:40 +00:00
Julian Seward
f0d678baab These files all speak about instrumentation functions.
Instrumentation functions now take a callback closure structure
(VgCallbackClosure*), so this commit changes the signatures
accordingly.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@5535
2006-01-17 02:06:39 +00:00
Julian Seward
dd3b4bf6f2 amd64-linux adjustments as a followup to r5493.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@5494
2006-01-04 02:55:03 +00:00
Julian Seward
32f134b8c1 Somewhat rehash the biarch-build machinery so as to (1) formalise the
distinction between primary and secondary build targets, and (2) make
it independent of the default behaviour of gcc (iow, what gcc does
when you specify neither -m32 nor -m64).

As a result, an out-of-the-box build on ppc64-linux now builds a
system which is basically for 64-bit PowerPC, but also has the ability
to run 32-bit ppc-linux binaries (exactly the same arrangement as you
get when building on amd64-linux).

There are various twists and turns.  multiple-architectures.txt is
updated all the gory details.

This will break amd64 builds until such time as
<tool>/tests/{amd64,x86}/Makefile.am are fixed up (shortly).



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@5493
2006-01-04 01:20:28 +00:00
Nicholas Nethercote
7683c8c703 Fix a nasty 64-bit-uncleanness bug in OSet spotted by Julian -- for fast
comparisons it was only considering the bottom 32-bits of the key.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@5427
2005-12-24 03:10:56 +00:00
Julian Seward
ad2d83c77b ppc64-linux fixes.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@5421
2005-12-23 12:47:42 +00:00
Nicholas Nethercote
9f216ffd28 Add the name of the input file to cg_annotate's output.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@5401
2005-12-22 06:14:42 +00:00
Nicholas Nethercote
ddb8c4241a Fixed cg_annotate bug -- when using the --sort option the primary threshold
was set to zero and so no annotation was done.  

Also put the file format into this file, and some other tiny changes.



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@5396
2005-12-21 19:45:29 +00:00
Nicholas Nethercote
3866282110 Remove all remaining profiling gunk.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@5388
2005-12-19 22:48:39 +00:00