diff options
author | steven <steven@138bc75d-0d04-0410-961f-82ee72b054a4> | 2012-12-13 10:02:39 +0000 |
---|---|---|
committer | steven <steven@138bc75d-0d04-0410-961f-82ee72b054a4> | 2012-12-13 10:02:39 +0000 |
commit | bb4df124a30b0d41cbfba4692a03dfaff376a6db (patch) | |
tree | 46c9cfb303f00460e680848a30891bee2e57b132 /gcc/bitmap.h | |
parent | 46ce857e6b81882f8713c74ae9ccb8cb9771aa37 (diff) | |
download | gcc-bb4df124a30b0d41cbfba4692a03dfaff376a6db.tar.gz |
* bitmap.c (struct bitmap_descriptor): Remove forward declaration.
(struct bitmap_head_def): Remove desc pointer. Add descriptor_id
field. Reorder fields for pointer alignment.
* bitmap.c: Include vec.h.
(struct bitmap_descriptor): Rename to bitmap_descriptor_d.
(bitmap_descriptor): New typedef, pointer to bitmap_descriptor_d.
Update all struct bitmap_descriptor references.
(next_bitmap_desc_id): New running index for bitmap desciptors.
(bitmap_descriptors): Vec of all bitmap descriptors by descriptor id.
(hash_descriptor, eq_descriptor): Update for struct bitmap_descriptor
change.
(bitmap_descriptor): Rename function to get_bitmap_descriptor.
Stuff newly allocated bitmap descriptor into bitmap_descriptors.
Set the bitmap descriptor id.
(bitmap_register): Lookup bitmap desciptor and store its ID in
the passed bitmap.
(register_overhead): Likewise.
(bitmap_find_bit): Lookup descriptor by id in bitmap_descriptors.
(print_statistics): Update for struct bitmap_descriptor change.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@194469 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/bitmap.h')
-rw-r--r-- | gcc/bitmap.h | 14 |
1 files changed, 6 insertions, 8 deletions
diff --git a/gcc/bitmap.h b/gcc/bitmap.h index 785ce3c48d7..402aac2f06f 100644 --- a/gcc/bitmap.h +++ b/gcc/bitmap.h @@ -174,20 +174,18 @@ typedef struct GTY((chain_next ("%h.next"), chain_prev ("%h.prev"))) bitmap_elem BITMAP_WORD bits[BITMAP_ELEMENT_WORDS]; /* Bits that are set. */ } bitmap_element; -struct bitmap_descriptor; -/* Head of bitmap linked list. gengtype ignores ifdefs, but for - statistics we need to add a bitmap descriptor pointer. As it is - not collected, we can just GTY((skip(""))) it. Likewise current - points to something already pointed to by the chain started by first, - no need to walk it again. */ +/* Head of bitmap linked list. The 'current' member points to something + already pointed to by the chain started by first, so GTY((skip)) it. */ typedef struct GTY(()) bitmap_head_def { + unsigned int indx; /* Index of last element looked at. */ + unsigned int descriptor_id; /* Unique identifier for the allocation + site of this bitmap, for detailed + statistics gathering. */ bitmap_element *first; /* First element in linked list. */ bitmap_element * GTY((skip(""))) current; /* Last element looked at. */ - unsigned int indx; /* Index of last element looked at. */ bitmap_obstack *obstack; /* Obstack to allocate elements from. If NULL, then use GGC allocation. */ - struct bitmap_descriptor GTY((skip(""))) *desc; } bitmap_head; /* Global data */ |