vg_symtab2.c:
    Discovered sometimes a SLINE stabs entry is the last one (which broke an
    assertion).  In such a case, we must guess the line's instruction address
    range -- I've guessed 4, arbitrarily.

vg_cachegen.in, vg_cachesim_{I1,D1,L2}.c:
    Discovered a bad bug in the cache simulation:  when determining if a
    references straddles two memory blocks, to find the end of the range I was
    adding 'size' to the base address, rather than 'size - 1'.  This was
    causing way too many straddled references, which would inflate the miss
    counts.

vg_cachesim.c:
    Minor stuff


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@176 a5019735-40e9-0310-863c-91ae7b9d1cf9
diff --git a/vg_cachesim_I1.c b/vg_cachesim_I1.c
index 32b89b5..96e9edd 100644
--- a/vg_cachesim_I1.c
+++ b/vg_cachesim_I1.c
@@ -22,8 +22,8 @@
 static __inline__ 
 void cachesim_I1_doref(Addr a, UChar size, ULong* m1, ULong *m2)
 {
-   register UInt set1 = ( a         >> 6) & (512-1);
-   register UInt set2 = ((a + size) >> 6) & (512-1);
+   register UInt set1 = ( a             >> 6) & (512-1);
+   register UInt set2 = ((a + size - 1) >> 6) & (512-1);
    register UInt tag  = a >> (6 + 9);
 
    if (set1 == set2) {