projects
/
platform
/
upstream
/
linaro-gcc.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
460acfe
)
* sbitmap.c (sbitmap_ones): Don't set too many bits.
author
rth
<rth@138bc75d-0d04-0410-961f-82ee72b054a4>
Mon, 4 Oct 1999 18:39:19 +0000
(18:39 +0000)
committer
rth
<rth@138bc75d-0d04-0410-961f-82ee72b054a4>
Mon, 4 Oct 1999 18:39:19 +0000
(18:39 +0000)
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@29807
138bc75d
-0d04-0410-961f-
82ee72b054a4
gcc/sbitmap.c
patch
|
blob
|
history
diff --git
a/gcc/sbitmap.c
b/gcc/sbitmap.c
index
89d6600
..
8aae23a
100644
(file)
--- a/
gcc/sbitmap.c
+++ b/
gcc/sbitmap.c
@@
-115,7
+115,16
@@
void
sbitmap_ones (bmap)
sbitmap bmap;
{
+ unsigned int last_bit;
+
memset (bmap->elms, -1, bmap->bytes);
+
+ last_bit = bmap->n_bits % (unsigned) SBITMAP_ELT_BITS;
+ if (last_bit)
+ {
+ bmap->elms[bmap->size - 1]
+ = (SBITMAP_ELT_TYPE)-1 >> (SBITMAP_ELT_BITS - last_bit);
+ }
}
/* Zero a vector of N_VECS bitmaps. */
@@
-208,7
+217,7
@@
sbitmap_difference (dst, a, b)
*dstp++ = *ap++ & (~*bp++);
}
-/* Set DST to be (A and B)
)
.
+/* Set DST to be (A and B).
Return non-zero if any change is made. */
int