summaryrefslogtreecommitdiff
path: root/gcc/bitmap.c
diff options
context:
space:
mode:
authorNathan Sidwell <nathan@codesourcery.com>2004-11-25 10:31:38 +0000
committerNathan Sidwell <nathan@gcc.gnu.org>2004-11-25 10:31:38 +0000
commitcc175e7c89539b0b55ef73c0ba9c7a6e062cc0d4 (patch)
tree60167593bb07447210914ff3d3ea5ed5f3a01a6a /gcc/bitmap.c
parentd0397fd9704cffd78f00ba2f74add6a46a4c3044 (diff)
basic-block.h (OBSTACK_ALLOC_REG_SET): Adjust.
* basic-block.h (OBSTACK_ALLOC_REG_SET): Adjust. (FREE_REG_SET): Adjust. * bitmap.c (bitmap_obstack_free): Cope with NULL bitmap. * bitmap.h (BITMAP_OBSTACK_ALLOC): Rename to ... (BITMAP_ALLOC): ... here. (BITMAP_OBSTACK_FREE): Rename to ... (BITMAP_FREE): Don't check for NULL bitmap here. * tree-ssa-pre.c (value_insert_into_set_bitmap, bitmap_set_new): Use new names. From-SVN: r91281
Diffstat (limited to 'gcc/bitmap.c')
-rw-r--r--gcc/bitmap.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/gcc/bitmap.c b/gcc/bitmap.c
index cbedf2c7b1a..275e440d6c3 100644
--- a/gcc/bitmap.c
+++ b/gcc/bitmap.c
@@ -241,9 +241,12 @@ bitmap_malloc_alloc (void)
void
bitmap_obstack_free (bitmap map)
{
- bitmap_clear (map);
- map->first = (void *)map->obstack->heads;
- map->obstack->heads = map;
+ if (map)
+ {
+ bitmap_clear (map);
+ map->first = (void *)map->obstack->heads;
+ map->obstack->heads = map;
+ }
}
/* Release a malloc allocated bitmap. */