Reworked rbyd/btree/mdir structs to allow better access to subcomponents
This turned out to be tricky.
At littlefs's core, we have the lfsr_rbyd_t struct. It is really
important this is as small as possible since littlefs creates many rbyd
copies in order to track state of metadata on disk.
Wrapping rbyd, we have the lfsr_btree_t struct, which can alternatively
contain a single inlined entry, accomplished by overlapping the width
field in both cases. And the lfsr_mdir_t struct, which tracks any redundant
blocks, and would be nice if the blocks lined up as neighbors so all blocks
involved in the mdir could be passed around as an array. Both of these
wrappers attempt to overlap fields of the lfsr_rbyd_t struct, which presents
a bit of a problem.
The solution here is to put the rbyd block field at the beginning of the
lfsr_rbyd_t struct, and use exactly 32-bits of padding in lfsr_btree_t
to overlap the width field even though it is not at the beginning of the
struct. To avoid inflating the lfsr_btree_t size, we sneak the inlined
size and tag into the overlapping padding. This will need special
handling if the size of these fields change, but saves a decent amount
of RAM:
lfsr_rbyd_t lfsr_btree_t lfsr_mdir_t
8b 8b 8b 8b
.----+----+----+----.
| mid.bid | mid.rid |
|----+----+----+----|
8b 8b 8b 8b 8b 8b 8b 8b | blocks |
.----+----+----+----. .----+----+----+----. | |
| block |..| tag |size|padd|.>| |
|----+----+----+----| |----+----+----+----| |----+----+----+----|
| weight |.>| weight | | weight |
|----+----+----+----| |----+----+----+----| |----+----+----+----|
| trunk | | inlined data | | trunk |
|----+----+----+----| | | | |----+----+----+----|
| off | | v | | off |
|----+----+----+----| | | |----+----+----+----|
| crc | | | | crc |
'----+----+----+----' '----+----+----+----' '----+----+----+----'
Also tried to reduce the amount of mdir usage in lfsr_mdir_commit by
better using only the arrays of relevant mdir blocks, to limited success.
This commit is contained in:
@@ -53,8 +53,13 @@ typedef uint16_t lfsr_mrid_t;
|
||||
typedef int16_t lfsr_smrid_t;
|
||||
|
||||
typedef struct lfsr_mid {
|
||||
#ifdef LFS_BIG_ENDIAN
|
||||
lfsr_smbid_t bid;
|
||||
lfsr_smrid_t rid;
|
||||
#else
|
||||
lfsr_smrid_t rid;
|
||||
lfsr_smbid_t bid;
|
||||
#endif
|
||||
} lfsr_mid_t;
|
||||
|
||||
// Maximum name size in bytes, may be redefined to reduce the size of the
|
||||
@@ -341,12 +346,13 @@ typedef struct lfs_cache {
|
||||
|
||||
// TODO do we get ram savings with a lfsr_rorbyd_t substruct? need to measure
|
||||
typedef struct lfsr_rbyd {
|
||||
// note this lines up with arrays of redundant blocks in other structures
|
||||
lfs_block_t block;
|
||||
// note this lines up with weight in lfsr_btree_t
|
||||
lfs_size_t weight;
|
||||
lfs_block_t block;
|
||||
// off=0, trunk=0 => not yet committed
|
||||
// off=0, trunk>0 => not yet fetched
|
||||
// off=block_size => rbyd not erased/needs compaction
|
||||
// off=0, trunk=0 => not yet committed
|
||||
// off=0, trunk>0 => not yet fetched
|
||||
// off>=block_size => rbyd not erased/needs compaction
|
||||
lfs_off_t trunk;
|
||||
lfs_off_t off;
|
||||
uint32_t crc;
|
||||
@@ -361,30 +367,44 @@ typedef struct lfsr_rbyd {
|
||||
// - mdir addresses => 2 leb128 => 10 bytes (worst case)
|
||||
#define LFSR_BTREE_INLINESIZE 10
|
||||
|
||||
typedef union lfsr_btree {
|
||||
// note this lines up with weight in lfsr_rbyd_t
|
||||
//
|
||||
// sign(weight)=1 => inlined btree
|
||||
// sign(weight)=0 => normal btree
|
||||
//
|
||||
// note due to defered inlining, both normal and inlined
|
||||
// btrees can have a weight of 0
|
||||
lfs_size_t weight;
|
||||
lfsr_rbyd_t root;
|
||||
struct {
|
||||
lfs_ssize_t weight;
|
||||
lfsr_tag_t tag;
|
||||
uint16_t size;
|
||||
uint8_t buffer[LFSR_BTREE_INLINESIZE];
|
||||
} inlined;
|
||||
typedef struct lfsr_btree {
|
||||
union {
|
||||
// weight is common to both representations and its sign-bit indicates
|
||||
// if the btree is inlined
|
||||
struct {
|
||||
lfs_size_t _padding;
|
||||
lfs_size_t weight;
|
||||
} b;
|
||||
struct {
|
||||
// TODO complex ifdefs here to handle tag/size > 1/2 a word?
|
||||
lfsr_tag_t tag;
|
||||
uint8_t size;
|
||||
uint8_t _padding;
|
||||
lfs_size_t weight;
|
||||
uint8_t buffer[LFSR_BTREE_INLINESIZE];
|
||||
} i;
|
||||
struct {
|
||||
// note the sign bit of the rbyd.block indicates if the btree is
|
||||
// inlined or a normal btree
|
||||
lfsr_rbyd_t rbyd;
|
||||
} r;
|
||||
} u;
|
||||
} lfsr_btree_t;
|
||||
|
||||
typedef struct lfsr_mdir {
|
||||
lfsr_mid_t mid;
|
||||
struct {
|
||||
lfsr_rbyd_t rbyd;
|
||||
lfs_block_t redund_block;
|
||||
} m;
|
||||
union {
|
||||
// here we make sure to line up our block array so it overlaps with
|
||||
// the block stored as the first entry in the rbyd
|
||||
struct {
|
||||
lfs_block_t blocks[2];
|
||||
lfs_size_t weight;
|
||||
} m;
|
||||
struct {
|
||||
lfs_block_t redund_block;
|
||||
lfsr_rbyd_t rbyd;
|
||||
} r;
|
||||
} u;
|
||||
} lfsr_mdir_t;
|
||||
|
||||
typedef struct lfsr_openedmdir {
|
||||
|
||||
+29
-14
@@ -108,6 +108,31 @@ extern "C"
|
||||
#endif
|
||||
#endif
|
||||
|
||||
// We need to know the endianness of the system for some struct packing
|
||||
#if (defined(BYTE_ORDER) \
|
||||
&& defined(ORDER_LITTLE_ENDIAN) \
|
||||
&& BYTE_ORDER == ORDER_LITTLE_ENDIAN) \
|
||||
|| (defined(__BYTE_ORDER) \
|
||||
&& defined(__ORDER_LITTLE_ENDIAN) \
|
||||
&& __BYTE_ORDER == __ORDER_LITTLE_ENDIAN) \
|
||||
|| (defined(__BYTE_ORDER__) \
|
||||
&& defined(__ORDER_LITTLE_ENDIAN__) \
|
||||
&& __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__)
|
||||
#define LFS_LITTLE_ENDIAN
|
||||
#elif (defined(BYTE_ORDER) \
|
||||
&& defined(ORDER_BIG_ENDIAN) \
|
||||
&& BYTE_ORDER == ORDER_BIG_ENDIAN) \
|
||||
|| (defined(__BYTE_ORDER) \
|
||||
&& defined(__ORDER_BIG_ENDIAN) \
|
||||
&& __BYTE_ORDER == __ORDER_BIG_ENDIAN) \
|
||||
|| (defined(__BYTE_ORDER__) \
|
||||
&& defined(__ORDER_BIG_ENDIAN__) \
|
||||
&& __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__)
|
||||
#define LFS_BIG_ENDIAN
|
||||
#else
|
||||
#error "lfs: Unknown endianness?"
|
||||
#endif
|
||||
|
||||
|
||||
// Builtin functions, these may be replaced by more efficient
|
||||
// toolchain-specific implementations. LFS_NO_INTRINSICS falls back to a more
|
||||
@@ -243,14 +268,9 @@ static inline int lfs_scmp(uint32_t a, uint32_t b) {
|
||||
|
||||
// Convert between 32-bit little-endian and native order
|
||||
static inline uint32_t lfs_fromle32(uint32_t a) {
|
||||
#if (defined( BYTE_ORDER ) && defined( ORDER_LITTLE_ENDIAN ) && BYTE_ORDER == ORDER_LITTLE_ENDIAN ) || \
|
||||
(defined(__BYTE_ORDER ) && defined(__ORDER_LITTLE_ENDIAN ) && __BYTE_ORDER == __ORDER_LITTLE_ENDIAN ) || \
|
||||
(defined(__BYTE_ORDER__) && defined(__ORDER_LITTLE_ENDIAN__) && __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__)
|
||||
#if !defined(LFS_NO_INTRINSICS) && defined(LFS_LITTLE_ENDIAN)
|
||||
return a;
|
||||
#elif !defined(LFS_NO_INTRINSICS) && ( \
|
||||
(defined( BYTE_ORDER ) && defined( ORDER_BIG_ENDIAN ) && BYTE_ORDER == ORDER_BIG_ENDIAN ) || \
|
||||
(defined(__BYTE_ORDER ) && defined(__ORDER_BIG_ENDIAN ) && __BYTE_ORDER == __ORDER_BIG_ENDIAN ) || \
|
||||
(defined(__BYTE_ORDER__) && defined(__ORDER_BIG_ENDIAN__) && __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__))
|
||||
#elif !defined(LFS_NO_INTRINSICS)
|
||||
return __builtin_bswap32(a);
|
||||
#else
|
||||
return (((uint8_t*)&a)[0] << 0) |
|
||||
@@ -266,14 +286,9 @@ static inline uint32_t lfs_tole32(uint32_t a) {
|
||||
|
||||
// Convert between 32-bit big-endian and native order
|
||||
static inline uint32_t lfs_frombe32(uint32_t a) {
|
||||
#if !defined(LFS_NO_INTRINSICS) && ( \
|
||||
(defined( BYTE_ORDER ) && defined( ORDER_LITTLE_ENDIAN ) && BYTE_ORDER == ORDER_LITTLE_ENDIAN ) || \
|
||||
(defined(__BYTE_ORDER ) && defined(__ORDER_LITTLE_ENDIAN ) && __BYTE_ORDER == __ORDER_LITTLE_ENDIAN ) || \
|
||||
(defined(__BYTE_ORDER__) && defined(__ORDER_LITTLE_ENDIAN__) && __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__))
|
||||
#if !defined(LFS_NO_INTRINSICS) && defined(LFS_LITTLE_ENDIAN)
|
||||
return __builtin_bswap32(a);
|
||||
#elif (defined( BYTE_ORDER ) && defined( ORDER_BIG_ENDIAN ) && BYTE_ORDER == ORDER_BIG_ENDIAN ) || \
|
||||
(defined(__BYTE_ORDER ) && defined(__ORDER_BIG_ENDIAN ) && __BYTE_ORDER == __ORDER_BIG_ENDIAN ) || \
|
||||
(defined(__BYTE_ORDER__) && defined(__ORDER_BIG_ENDIAN__) && __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__)
|
||||
#elif !defined(LFS_NO_INTRINSICS)
|
||||
return a;
|
||||
#else
|
||||
return (((uint8_t*)&a)[0] << 24) |
|
||||
|
||||
@@ -149,7 +149,7 @@ code = '''
|
||||
lfsr_mdir_t mdir;
|
||||
lfsr_mtree_lookup(&lfs, LFSR_MID(mid, -1), &mdir) => 0;
|
||||
for (mdir.mid.rid = 0;
|
||||
mdir.mid.rid < (lfs_ssize_t)mdir.m.rbyd.weight;
|
||||
mdir.mid.rid < (lfs_ssize_t)mdir.u.m.weight;
|
||||
mdir.mid.rid++) {
|
||||
uint8_t buffer[4];
|
||||
lfsr_mdir_get(&lfs, &mdir, mdir.mid.rid, LFSR_TAG_INLINED,
|
||||
|
||||
+195
-195
@@ -23,9 +23,9 @@ code = '''
|
||||
// create an empty tree
|
||||
lfsr_btree_t btree = LFSR_BTREE_NULL;
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
assert(lfsr_btree_weight(&btree) == 0);
|
||||
|
||||
// try looking up tags
|
||||
@@ -56,9 +56,9 @@ code = '''
|
||||
lfsr_btree_push(&lfs, &btree, 0, LFSR_TAG_INLINED, 1,
|
||||
LFSR_DATA_BUF("a", 1)) => 0;
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
assert(lfsr_btree_weight(&btree) == 1);
|
||||
|
||||
// try looking up tags
|
||||
@@ -97,9 +97,9 @@ code = '''
|
||||
lfsr_btree_push(&lfs, &btree, 1, LFSR_TAG_INLINED, 1,
|
||||
LFSR_DATA_BUF("b", 1)) => 0;
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
assert(lfsr_btree_weight(&btree) == 2);
|
||||
|
||||
// try looking up tags
|
||||
@@ -143,9 +143,9 @@ code = '''
|
||||
lfsr_btree_push(&lfs, &btree, 0, LFSR_TAG_INLINED, 1,
|
||||
LFSR_DATA_BUF("a", 1)) => 0;
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
assert(lfsr_btree_weight(&btree) == 2);
|
||||
|
||||
// try looking up tags
|
||||
@@ -192,9 +192,9 @@ code = '''
|
||||
lfsr_btree_push(&lfs, &btree, 2, LFSR_TAG_INLINED, 1,
|
||||
LFSR_DATA_BUF("c", 1)) => 0;
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
assert(lfsr_btree_weight(&btree) == 3);
|
||||
|
||||
// try looking up tags
|
||||
@@ -246,9 +246,9 @@ code = '''
|
||||
lfsr_btree_push(&lfs, &btree, 0, LFSR_TAG_INLINED, 1,
|
||||
LFSR_DATA_BUF("a", 1)) => 0;
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
assert(lfsr_btree_weight(&btree) == 3);
|
||||
|
||||
// try looking up tags
|
||||
@@ -309,9 +309,9 @@ code = '''
|
||||
n += 1;
|
||||
}
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
assert(lfsr_btree_weight(&btree) == n);
|
||||
|
||||
// check that the elements are in the tree
|
||||
@@ -361,9 +361,9 @@ code = '''
|
||||
n += 1;
|
||||
}
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
assert(lfsr_btree_weight(&btree) == n);
|
||||
|
||||
// check that the elements are in the tree
|
||||
@@ -444,9 +444,9 @@ code = '''
|
||||
}
|
||||
printf("]\n");
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
assert(lfsr_btree_weight(&btree) == sim_size);
|
||||
|
||||
uint8_t buffer[4];
|
||||
@@ -499,9 +499,9 @@ code = '''
|
||||
n += 1;
|
||||
}
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
assert(lfsr_btree_weight(&btree) == n*W);
|
||||
|
||||
// check that the elements are in the tree
|
||||
@@ -620,9 +620,9 @@ code = '''
|
||||
}
|
||||
printf("]\n");
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
|
||||
lfs_size_t total_weight = 0;
|
||||
for (lfs_size_t j = 0; j < sim_size; j++) {
|
||||
@@ -702,9 +702,9 @@ code = '''
|
||||
lfsr_btree_set(&lfs, &btree, 0, LFSR_TAG_INLINED, 1,
|
||||
LFSR_DATA_BUF("A", 1)) => 0;
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
assert(lfsr_btree_weight(&btree) == 1);
|
||||
|
||||
// try looking up tags
|
||||
@@ -747,9 +747,9 @@ code = '''
|
||||
lfsr_btree_set(&lfs, &btree, 1, LFSR_TAG_INLINED, 1,
|
||||
LFSR_DATA_BUF("B", 1)) => 0;
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
assert(lfsr_btree_weight(&btree) == 2);
|
||||
|
||||
// try looking up tags
|
||||
@@ -802,9 +802,9 @@ code = '''
|
||||
lfsr_btree_set(&lfs, &btree, 2, LFSR_TAG_INLINED, 1,
|
||||
LFSR_DATA_BUF("C", 1)) => 0;
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
assert(lfsr_btree_weight(&btree) == 3);
|
||||
|
||||
// try looking up tags
|
||||
@@ -858,9 +858,9 @@ code = '''
|
||||
// ignore space issues
|
||||
if (err == LFS_ERR_NOSPC) {
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
return;
|
||||
}
|
||||
assert(err == 0);
|
||||
@@ -872,17 +872,17 @@ code = '''
|
||||
// ignore space issues
|
||||
if (err == LFS_ERR_NOSPC) {
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
return;
|
||||
}
|
||||
assert(err == 0);
|
||||
}
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
assert(lfsr_btree_weight(&btree) == N);
|
||||
|
||||
// check that the elements are in the tree
|
||||
@@ -930,9 +930,9 @@ code = '''
|
||||
// ignore space issues
|
||||
if (err == LFS_ERR_NOSPC) {
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
return;
|
||||
}
|
||||
assert(err == 0);
|
||||
@@ -977,9 +977,9 @@ code = '''
|
||||
}
|
||||
printf("]\n");
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
assert(lfsr_btree_weight(&btree) == N);
|
||||
|
||||
uint8_t buffer[4];
|
||||
@@ -1026,9 +1026,9 @@ code = '''
|
||||
// ignore space issues
|
||||
if (err == LFS_ERR_NOSPC) {
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
return;
|
||||
}
|
||||
assert(err == 0);
|
||||
@@ -1040,17 +1040,17 @@ code = '''
|
||||
// ignore space issues
|
||||
if (err == LFS_ERR_NOSPC) {
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
return;
|
||||
}
|
||||
assert(err == 0);
|
||||
}
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
assert(lfsr_btree_weight(&btree) == N*W);
|
||||
|
||||
// check that the elements are in the tree
|
||||
@@ -1114,9 +1114,9 @@ code = '''
|
||||
// ignore space issues
|
||||
if (err == LFS_ERR_NOSPC) {
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
return;
|
||||
}
|
||||
assert(err == 0);
|
||||
@@ -1180,9 +1180,9 @@ code = '''
|
||||
}
|
||||
printf("]\n");
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
|
||||
lfs_size_t total_weight = 0;
|
||||
for (lfs_size_t j = 0; j < N; j++) {
|
||||
@@ -1262,9 +1262,9 @@ code = '''
|
||||
// pop!
|
||||
lfsr_btree_pop(&lfs, &btree, 0) => 0;
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
assert(lfsr_btree_weight(&btree) == 0);
|
||||
|
||||
// try looking up tags
|
||||
@@ -1279,9 +1279,9 @@ code = '''
|
||||
lfsr_btree_push(&lfs, &btree, 0, LFSR_TAG_INLINED, 1,
|
||||
LFSR_DATA_BUF("A", 1)) => 0;
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
assert(lfsr_btree_weight(&btree) == 1);
|
||||
|
||||
// try looking up tags
|
||||
@@ -1317,9 +1317,9 @@ code = '''
|
||||
// pop!
|
||||
lfsr_btree_pop(&lfs, &btree, 1) => 0;
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
assert(lfsr_btree_weight(&btree) == 1);
|
||||
|
||||
// try looking up tags
|
||||
@@ -1340,9 +1340,9 @@ code = '''
|
||||
lfsr_btree_push(&lfs, &btree, 1, LFSR_TAG_INLINED, 1,
|
||||
LFSR_DATA_BUF("B", 1)) => 0;
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
assert(lfsr_btree_weight(&btree) == 2);
|
||||
|
||||
// try looking up tags
|
||||
@@ -1384,9 +1384,9 @@ code = '''
|
||||
// pop!
|
||||
lfsr_btree_pop(&lfs, &btree, 0) => 0;
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
assert(lfsr_btree_weight(&btree) == 1);
|
||||
|
||||
// try looking up tags
|
||||
@@ -1407,9 +1407,9 @@ code = '''
|
||||
lfsr_btree_push(&lfs, &btree, 0, LFSR_TAG_INLINED, 1,
|
||||
LFSR_DATA_BUF("A", 1)) => 0;
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
assert(lfsr_btree_weight(&btree) == 2);
|
||||
|
||||
// try looking up tags
|
||||
@@ -1453,9 +1453,9 @@ code = '''
|
||||
// pop!
|
||||
lfsr_btree_pop(&lfs, &btree, 2) => 0;
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
assert(lfsr_btree_weight(&btree) == 2);
|
||||
|
||||
// try looking up tags
|
||||
@@ -1482,9 +1482,9 @@ code = '''
|
||||
lfsr_btree_push(&lfs, &btree, 2, LFSR_TAG_INLINED, 1,
|
||||
LFSR_DATA_BUF("C", 1)) => 0;
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
assert(lfsr_btree_weight(&btree) == 3);
|
||||
|
||||
// try looking up tags
|
||||
@@ -1535,9 +1535,9 @@ code = '''
|
||||
// ignore space issues
|
||||
if (err == LFS_ERR_NOSPC) {
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
return;
|
||||
}
|
||||
assert(err == 0);
|
||||
@@ -1548,18 +1548,18 @@ code = '''
|
||||
// ignore space issues
|
||||
if (err == LFS_ERR_NOSPC) {
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
return;
|
||||
}
|
||||
assert(err == 0);
|
||||
}
|
||||
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
assert(lfsr_btree_weight(&btree) == REMAINING);
|
||||
|
||||
// check that the elements are in the tree
|
||||
@@ -1626,9 +1626,9 @@ code = '''
|
||||
// ignore space issues
|
||||
if (err == LFS_ERR_NOSPC) {
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
return;
|
||||
}
|
||||
assert(err == 0);
|
||||
@@ -1639,17 +1639,17 @@ code = '''
|
||||
// ignore space issues
|
||||
if (err == LFS_ERR_NOSPC) {
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
return;
|
||||
}
|
||||
assert(err == 0);
|
||||
}
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
assert(lfsr_btree_weight(&btree) == REMAINING);
|
||||
|
||||
// check that the elements are in the tree
|
||||
@@ -1718,9 +1718,9 @@ code = '''
|
||||
// ignore space issues
|
||||
if (err == LFS_ERR_NOSPC) {
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
return;
|
||||
}
|
||||
assert(err == 0);
|
||||
@@ -1766,9 +1766,9 @@ code = '''
|
||||
}
|
||||
printf("]\n");
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
assert(lfsr_btree_weight(&btree) == sim_size);
|
||||
|
||||
uint8_t buffer[4];
|
||||
@@ -1816,9 +1816,9 @@ code = '''
|
||||
// ignore space issues
|
||||
if (err == LFS_ERR_NOSPC) {
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
return;
|
||||
}
|
||||
assert(err == 0);
|
||||
@@ -1829,17 +1829,17 @@ code = '''
|
||||
// ignore space issues
|
||||
if (err == LFS_ERR_NOSPC) {
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
return;
|
||||
}
|
||||
assert(err == 0);
|
||||
}
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
assert(lfsr_btree_weight(&btree) == REMAINING*W);
|
||||
|
||||
// check that the elements are in the tree
|
||||
@@ -1956,9 +1956,9 @@ code = '''
|
||||
// ignore space issues
|
||||
if (err == LFS_ERR_NOSPC) {
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
return;
|
||||
}
|
||||
assert(err == 0);
|
||||
@@ -2013,9 +2013,9 @@ code = '''
|
||||
}
|
||||
printf("]\n");
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
|
||||
lfs_size_t total_weight = 0;
|
||||
for (lfs_size_t j = 0; j < sim_size; j++) {
|
||||
@@ -2104,9 +2104,9 @@ code = '''
|
||||
n += 1;
|
||||
}
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
assert(lfsr_btree_weight(&btree) == n);
|
||||
|
||||
// check that the elements are in the tree
|
||||
@@ -2193,9 +2193,9 @@ code = '''
|
||||
}
|
||||
printf("]\n");
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
assert(lfsr_btree_weight(&btree) == sim_size);
|
||||
|
||||
uint8_t buffer[4];
|
||||
@@ -2251,9 +2251,9 @@ code = '''
|
||||
n += 1;
|
||||
}
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
assert(lfsr_btree_weight(&btree) == n*W);
|
||||
|
||||
// check that the elements are in the tree
|
||||
@@ -2367,9 +2367,9 @@ code = '''
|
||||
}
|
||||
printf("]\n");
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
|
||||
lfs_size_t total_weight = 0;
|
||||
for (lfs_size_t j = 0; j < sim_size; j++) {
|
||||
@@ -2519,9 +2519,9 @@ code = '''
|
||||
}
|
||||
printf("]\n");
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
assert(lfsr_btree_weight(&btree) == sim_size);
|
||||
|
||||
uint8_t buffer[4];
|
||||
@@ -2660,9 +2660,9 @@ code = '''
|
||||
}
|
||||
printf("]\n");
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
|
||||
lfs_size_t total_weight = 0;
|
||||
for (lfs_size_t j = 0; j < sim_size; j++) {
|
||||
@@ -2735,9 +2735,9 @@ code = '''
|
||||
// create a zero-entry tree
|
||||
lfsr_btree_t btree = LFSR_BTREE_NULL;
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
assert(lfsr_btree_weight(&btree) == 0);
|
||||
|
||||
// try to find tags
|
||||
@@ -2770,9 +2770,9 @@ code = '''
|
||||
lfsr_btree_push(&lfs, &btree, 0, LFSR_TAG_INLINED, 1,
|
||||
LFSR_DATA_BUF("0", 1)) => 0;
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
assert(lfsr_btree_weight(&btree) == 1);
|
||||
|
||||
// try to find tags
|
||||
@@ -2822,9 +2822,9 @@ code = '''
|
||||
LFSR_TAG_INLINED, 1, LFSR_DATA_BUF("0", 1),
|
||||
LFSR_TAG_INLINED, 1, LFSR_DATA_BUF("1", 1)) => 0;
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
assert(lfsr_btree_weight(&btree) == 2);
|
||||
|
||||
// try to find tags
|
||||
@@ -2885,9 +2885,9 @@ code = '''
|
||||
LFSR_TAG_INLINED, 1, LFSR_DATA_BUF("1", 1),
|
||||
LFSR_TAG_INLINED, 1, LFSR_DATA_BUF("2", 1)) => 0;
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
assert(lfsr_btree_weight(&btree) == 3);
|
||||
|
||||
// try to find tags
|
||||
@@ -2956,9 +2956,9 @@ code = '''
|
||||
LFSR_TAG_INLINED, 1, LFSR_DATA_BUF("0", 1),
|
||||
LFSR_TAG_INLINED, 1, LFSR_DATA_BUF("1", 1)) => 0;
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
assert(lfsr_btree_weight(&btree) == 3);
|
||||
|
||||
// try to find tags
|
||||
@@ -3040,9 +3040,9 @@ code = '''
|
||||
n += 1;
|
||||
}
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
assert(lfsr_btree_weight(&btree) == n);
|
||||
|
||||
// try to find tags
|
||||
@@ -3152,9 +3152,9 @@ code = '''
|
||||
}
|
||||
printf("]\n");
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
assert(lfsr_btree_weight(&btree) == sim_size);
|
||||
|
||||
uint8_t buffer[4];
|
||||
@@ -3218,9 +3218,9 @@ code = '''
|
||||
n += 1;
|
||||
}
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
assert(lfsr_btree_weight(&btree) == n*W);
|
||||
|
||||
// try to find tags
|
||||
@@ -3358,9 +3358,9 @@ code = '''
|
||||
}
|
||||
printf("]\n");
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
|
||||
lfs_size_t total_weight = 0;
|
||||
for (lfs_size_t j = 0; j < sim_size; j++) {
|
||||
@@ -3546,9 +3546,9 @@ code = '''
|
||||
}
|
||||
printf("]\n");
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
assert(lfsr_btree_weight(&btree) == sim_size);
|
||||
|
||||
uint8_t buffer[4];
|
||||
@@ -3756,9 +3756,9 @@ code = '''
|
||||
}
|
||||
printf("]\n");
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
|
||||
lfs_size_t total_weight = 0;
|
||||
for (lfs_size_t j = 0; j < sim_size; j++) {
|
||||
@@ -3826,9 +3826,9 @@ code = '''
|
||||
n += 1;
|
||||
}
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
assert(lfsr_btree_weight(&btree) == n);
|
||||
|
||||
// check that the elements are in the tree
|
||||
@@ -3975,9 +3975,9 @@ code = '''
|
||||
}
|
||||
printf("]\n");
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
assert(lfsr_btree_weight(&btree) == sim_size);
|
||||
|
||||
uint8_t buffer[4];
|
||||
@@ -4061,9 +4061,9 @@ code = '''
|
||||
}
|
||||
printf("]\n");
|
||||
printf("btree: w%d 0x%x.%x\n",
|
||||
btree.weight,
|
||||
btree.root.block,
|
||||
btree.root.trunk);
|
||||
btree.u.r.rbyd.weight,
|
||||
btree.u.r.rbyd.block,
|
||||
btree.u.r.rbyd.trunk);
|
||||
assert(lfsr_btree_weight(&btree) == sim_size);
|
||||
|
||||
for (lfs_size_t i = 0; i < sim_size; i++) {
|
||||
|
||||
+362
-357
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user