Am 26.09.2012 17:56, schrieb Paolo Bonzini:
HBitmaps provides an array of bits. The bits are stored as usual in an
array of unsigned longs, but HBitmap is also optimized to provide fast
iteration over set bits; going from one bit to the next is O(logB n)
worst case, with B = sizeof(long) *
Il 24/10/2012 16:41, Kevin Wolf ha scritto:
+struct HBitmapIter {
+const HBitmap *hb;
+
+/* Copied from hb for access in the inline functions (hb is opaque). */
+int granularity;
+
+/* Entry offset into the last-level array of longs. */
+size_t pos;
Other places,
Il 27/09/2012 04:53, Eric Blake ha scritto:
+++ b/hbitmap.c
@@ -0,0 +1,400 @@
+/*
+ * Hierarchical Bitmap Data Type
+ *
+ * Copyright Red Hat, Inc., 2012
vs.
+++ b/tests/test-hbitmap.c
@@ -0,0 +1,408 @@
+/*
+ * Hierarchical bitmap unit-tests.
+ *
+ * Copyright (C) 2012
HBitmaps provides an array of bits. The bits are stored as usual in an
array of unsigned longs, but HBitmap is also optimized to provide fast
iteration over set bits; going from one bit to the next is O(logB n)
worst case, with B = sizeof(long) * CHAR_BIT: the result is low enough
that the number
On 09/26/2012 09:56 AM, Paolo Bonzini wrote:
HBitmaps provides an array of bits. The bits are stored as usual in an
array of unsigned longs, but HBitmap is also optimized to provide fast
iteration over set bits; going from one bit to the next is O(logB n)
worst case, with B = sizeof(long) *