but the more memory wasted for sparse bitsets and the longer the time
to search for set bits. */
-#ifndef LBITSET_ELT_WORDS
#define LBITSET_ELT_WORDS 2
-#endif
typedef bitset_word lbitset_word;
}
else
{
- /* We can't use gcc_obstack_init to initialize the obstack since
- print-rtl.c now calls bitset functions, and bitset is linked
- into the gen* functions. */
if (!lbitset_obstack_init)
{
lbitset_obstack_init = 1;
}
-/* Allocate a lbitset element. The bits are not cleared. */
+/* Allocate a lbitset element. The bits are cleared. */
static inline lbitset_elt *
lbitset_elt_calloc ()
{
lbitset_elt_find (dst, windex, LBITSET_CREATE);
- dst->b.cdata[windex - dst->b.cindex] |= (1 << (bitno % BITSET_WORD_BITS));
+ dst->b.cdata[windex - dst->b.cindex] |=
+ (bitset_word) 1 << (bitno % BITSET_WORD_BITS);
}
if (!lbitset_elt_find (dst, windex, LBITSET_FIND))
return;
- dst->b.cdata[windex - dst->b.cindex] &= ~(1 << (bitno % BITSET_WORD_BITS));
+ dst->b.cdata[windex - dst->b.cindex] &=
+ ~((bitset_word) 1 << (bitno % BITSET_WORD_BITS));
/* If all the data is zero, perhaps we should unlink it now... */
}
{
/* Create new elements if they cannot be found. */
elt = lbitset_elt_find (dst, i, LBITSET_CREATE);
- memset (elt->words, ~0, sizeof (elt->words));
+ memset (elt->words, -1, sizeof (elt->words));
}
break;