summaryrefslogtreecommitdiff
path: root/gcc/sbitmap.h
diff options
context:
space:
mode:
authorcrowl <crowl@138bc75d-0d04-0410-961f-82ee72b054a4>2012-11-01 22:39:26 +0000
committercrowl <crowl@138bc75d-0d04-0410-961f-82ee72b054a4>2012-11-01 22:39:26 +0000
commit64764082dc6538b74abf3bff7a2fead2e0a0422b (patch)
tree721953d1607e06b4dcb3e4e0e522f8d20d151d17 /gcc/sbitmap.h
parentb336fdb568efa5d952d44c1fffcad5f5efc00a0c (diff)
downloadgcc-64764082dc6538b74abf3bff7a2fead2e0a0422b.tar.gz
This patch removes the unused ebitmap, and then removes some sbitmap functions
only used by ebitmap. The functions removed are: SET_BIT_WITH_POPCOUNT RESET_BIT_WITH_POPCOUNT bitmap_copy_n bitmap_range_empty_p sbitmap_popcount In addition, two functions have been made private to the implementation file: SBITMAP_SIZE_BYTES sbitmap_verify_popcount Tested on x86-64. Index: gcc/ChangeLog 2012-11-01 Lawrence Crowl <crowl@google.com> * ebitmap.h: Remove unused. * ebitmap.c: Remove unused. * Makefile.in: Remove ebitmap.h and ebitmap.c. * sbitmap.h (SBITMAP_SIZE_BYTES): Move to source file. (SET_BIT_WITH_POPCOUNT): Remove unused. (RESET_BIT_WITH_POPCOUNT): Remove unused. (bitmap_copy_n): Remove unused. (bitmap_range_empty_p): Remove unused. (sbitmap_popcount): Remove unused. (sbitmap_verify_popcount): Make private to source file. * sbitmap.c (SBITMAP_SIZE_BYTES): Move here from header. (bitmap_copy_n): Remove unused. (bitmap_range_empty_p): Remove unused. (sbitmap_popcount): Remove unused. (sbitmap_verify_popcount): Make private to source file. 2012-11-01 Lawrence Crowl <crowl@google.com> git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@193072 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/sbitmap.h')
-rw-r--r--gcc/sbitmap.h35
1 files changed, 1 insertions, 34 deletions
diff --git a/gcc/sbitmap.h b/gcc/sbitmap.h
index 96590d4e176..dce22d0faba 100644
--- a/gcc/sbitmap.h
+++ b/gcc/sbitmap.h
@@ -42,11 +42,10 @@ along with GCC; see the file COPYING3. If not see
the size of the set universe:
* clear : bitmap_clear
- * cardinality : sbitmap_popcount
* choose_one : bitmap_first_set_bit /
bitmap_last_set_bit
* forall : EXECUTE_IF_SET_IN_BITMAP
- * set_copy : bitmap_copy / bitmap_copy_n
+ * set_copy : bitmap_copy
* set_intersection : bitmap_and
* set_union : bitmap_ior
* set_difference : bitmap_and_compl
@@ -93,7 +92,6 @@ struct simple_bitmap_def
/* Return the set size needed for N elements. */
#define SBITMAP_SET_SIZE(N) (((N) + SBITMAP_ELT_BITS - 1) / SBITMAP_ELT_BITS)
-#define SBITMAP_SIZE_BYTES(BITMAP) ((BITMAP)->size * sizeof (SBITMAP_ELT_TYPE))
/* Return the number of bits in BITMAP. */
#define SBITMAP_SIZE(BITMAP) ((BITMAP)->n_bits)
@@ -117,20 +115,6 @@ bitmap_set_bit (sbitmap map, int bitno)
|= (SBITMAP_ELT_TYPE) 1 << (bitno) % SBITMAP_ELT_BITS;
}
-/* Like bitmap_set_bit, but updates population count. */
-
-static inline void
-bitmap_set_bit_with_popcount (sbitmap map, int bitno)
-{
- bool oldbit;
- gcc_checking_assert (map->popcount);
- oldbit = bitmap_bit_p (map, bitno);
- if (!oldbit)
- map->popcount[bitno / SBITMAP_ELT_BITS]++;
- map->elms[bitno / SBITMAP_ELT_BITS]
- |= (SBITMAP_ELT_TYPE) 1 << (bitno) % SBITMAP_ELT_BITS;
-}
-
/* Reset bit number BITNO in the sbitmap MAP. */
static inline void
@@ -141,20 +125,6 @@ bitmap_clear_bit (sbitmap map, int bitno)
&= ~((SBITMAP_ELT_TYPE) 1 << (bitno) % SBITMAP_ELT_BITS);
}
-/* Like bitmap_clear_bit, but updates population count. */
-
-static inline void
-bitmap_clear_bit_with_popcount (sbitmap map, int bitno)
-{
- bool oldbit;
- gcc_checking_assert (map->popcount);
- oldbit = bitmap_bit_p (map, bitno);
- if (oldbit)
- map->popcount[bitno / SBITMAP_ELT_BITS]--;
- map->elms[bitno / SBITMAP_ELT_BITS]
- &= ~((SBITMAP_ELT_TYPE) 1 << (bitno) % SBITMAP_ELT_BITS);
-}
-
/* The iterator for sbitmap. */
typedef struct {
/* The pointer to the first word of the bitmap. */
@@ -261,10 +231,8 @@ extern sbitmap sbitmap_alloc_with_popcount (unsigned int);
extern sbitmap *sbitmap_vector_alloc (unsigned int, unsigned int);
extern sbitmap sbitmap_resize (sbitmap, unsigned int, int);
extern void bitmap_copy (sbitmap, const_sbitmap);
-extern void bitmap_copy_n (sbitmap, const_sbitmap, unsigned int);
extern int bitmap_equal_p (const_sbitmap, const_sbitmap);
extern bool bitmap_empty_p (const_sbitmap);
-extern bool bitmap_range_empty_p (const_sbitmap, unsigned int, unsigned int);
extern void bitmap_clear (sbitmap);
extern void bitmap_ones (sbitmap);
extern void bitmap_vector_clear (sbitmap *, unsigned int);
@@ -290,5 +258,4 @@ extern int bitmap_last_set_bit (const_sbitmap);
extern void debug_bitmap (const_sbitmap);
extern sbitmap sbitmap_realloc (sbitmap, unsigned int);
extern unsigned long sbitmap_popcount (const_sbitmap, unsigned long);
-extern void sbitmap_verify_popcount (const_sbitmap);
#endif /* ! GCC_SBITMAP_H */