]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph-ci.git/commitdiff
test: Fix sign comparison warnings
authorAdam C. Emerson <aemerson@redhat.com>
Wed, 29 Aug 2018 19:39:09 +0000 (15:39 -0400)
committerAdam C. Emerson <aemerson@redhat.com>
Wed, 12 Sep 2018 16:41:40 +0000 (12:41 -0400)
Signed-off-by: Adam C. Emerson <aemerson@redhat.com>
13 files changed:
src/test/cls_rbd/test_cls_rbd.cc
src/test/cls_rgw/test_cls_rgw.cc
src/test/common/test_convenience.cc
src/test/libcephfs/deleg.cc
src/test/libcephfs/test.cc
src/test/librados/c_read_operations.cc
src/test/librados/tier.cc
src/test/msgr/test_msgr.cc
src/test/objectstore/Allocator_test.cc
src/test/objectstore/fastbmap_allocator_test.cc
src/test/objectstore/test_bluestore_types.cc
src/test/objectstore/test_memstore_clone.cc
src/test/test_ipaddr.cc

index 7eac1593ec817e641edb1ee7d6a134ff8bd05d9b..d2d5889c41e865715652003239c5b2a1b9687273 100644 (file)
@@ -2603,7 +2603,7 @@ TEST_F(TestClsRbd, op_features)
 
   uint64_t actual_op_features;
   ASSERT_EQ(0, op_features_get(&ioctx, oid, &actual_op_features));
-  ASSERT_EQ(0, actual_op_features);
+  ASSERT_EQ(0u, actual_op_features);
 
   uint64_t features;
   ASSERT_EQ(0, get_features(&ioctx, oid, CEPH_NOSNAP, &features));
index c97c7e354aa416175b1813378cc12dde728866c2..d09e867ec757dbd0560fec27a7d78ecc40ac7bad 100644 (file)
@@ -431,12 +431,12 @@ TEST(cls_rgw, index_list)
   int r = CLSRGWIssueBucketList(ioctx, start_key, "", 1000, true, oids, list_results, 1)();
 
   ASSERT_EQ(r, 0);
-  ASSERT_EQ(1, list_results.size());
+  ASSERT_EQ(1u, list_results.size());
 
   auto it = list_results.begin();
   auto m = (it->second).dir.m;
 
-  ASSERT_EQ(4, m.size());
+  ASSERT_EQ(4u, m.size());
   int i = 0;
   for(auto it2 = m.begin(); it2 != m.end(); it2++, i++)
     ASSERT_EQ(it2->first.compare(keys[i]), 0);
@@ -464,7 +464,7 @@ TEST(cls_rgw, bi_list)
   int ret = cls_rgw_bi_list(ioctx, bucket_oid, name, marker, max, &entries,
                            &is_truncated);
   ASSERT_EQ(ret, 0);
-  ASSERT_EQ(entries.size(), 0);
+  ASSERT_EQ(entries.size(), 0u);
   ASSERT_EQ(is_truncated, false);
 
   uint64_t epoch = 1;
@@ -511,7 +511,7 @@ TEST(cls_rgw, bi_list)
   ret = cls_rgw_bi_list(ioctx, bucket_oid, name, marker, max, &entries,
                        &is_truncated);
   ASSERT_EQ(ret, 0);
-  ASSERT_EQ(entries.size(), 0);
+  ASSERT_EQ(entries.size(), 0u);
   ASSERT_EQ(is_truncated, false);
 
   if (cct->_conf->osd_max_omap_entries_per_request < 15) {
@@ -536,7 +536,7 @@ TEST(cls_rgw, bi_list)
   ret = cls_rgw_bi_list(ioctx, bucket_oid, name, marker, max, &entries,
                        &is_truncated);
   ASSERT_EQ(ret, 0);
-  ASSERT_EQ(entries.size(), 0);
+  ASSERT_EQ(entries.size(), 0u);
   ASSERT_EQ(is_truncated, false);
 }
 
@@ -830,7 +830,7 @@ TEST(cls_rgw, usage_basic)
   // read the entries, and see that we have all the added entries
   ASSERT_EQ(0, ret);
   ASSERT_FALSE(truncated);
-  ASSERT_EQ(total_usage_entries, usage.size());
+  ASSERT_EQ(static_cast<uint64_t>(total_usage_entries), usage.size());
 
   // delete and read to assert that we've deleted all the values
   ASSERT_EQ(0, cls_rgw_usage_log_trim(ioctx, oid, user, start_epoch, end_epoch));
@@ -839,7 +839,7 @@ TEST(cls_rgw, usage_basic)
   ret = cls_rgw_usage_log_read(ioctx, oid, user, start_epoch, end_epoch,
                               max_entries, read_iter, usage2, &truncated);
   ASSERT_EQ(0, ret);
-  ASSERT_EQ(0, usage2.size());
+  ASSERT_EQ(0u, usage2.size());
 
 }
 
@@ -879,7 +879,7 @@ TEST(cls_rgw, usage_clear)
   ret = cls_rgw_usage_log_read(ioctx, oid, user, start_epoch, end_epoch,
                               max_entries, read_iter, usage, &truncated);
   ASSERT_EQ(0, ret);
-  ASSERT_EQ(0, usage.size());
+  ASSERT_EQ(0u, usage.size());
 
 }
 
index 6c25e2a6f5b50b0fb2925c66f9b29e36b2d4074d..4f4ba386e1c9619777230f06c0aec5d09dd5ea54 100644 (file)
@@ -44,7 +44,7 @@ TEST(Convenience, MaybeDoOr)
   auto r = ceph::maybe_do_or(s, l, 0);
   EXPECT_EQ(r, s->size());
 
-  EXPECT_EQ(ceph::maybe_do_or(t, l, 0), 0);
+  EXPECT_EQ(ceph::maybe_do_or(t, l, 0u), 0u);
 }
 
 TEST(Convenience, StdMaybeDo)
@@ -65,5 +65,5 @@ TEST(Convenience, StdMaybeDoOr)
   auto r = ceph::maybe_do_or(s, l, 0);
   EXPECT_EQ(r, s->size());
 
-  EXPECT_EQ(ceph::maybe_do_or(t, l, 0), 0);
+  EXPECT_EQ(ceph::maybe_do_or(t, l, 0u), 0u);
 }
index 2dc3b970213aba3d2f6ccfd71819690e85d6d078..24f353dbbef5a250f7e189cff447254d70e16eb9 100644 (file)
@@ -336,7 +336,8 @@ TEST(LibCephFS, RecalledGetattr) {
 
   ASSERT_EQ(ceph_ll_create(cmount1, root, filename, 0666,
                    O_RDWR|O_CREAT|O_EXCL, &file, &fh, &stx, 0, 0, perms), 0);
-  ASSERT_EQ(ceph_ll_write(cmount1, fh, 0, sizeof(filename), filename), sizeof(filename));
+  ASSERT_EQ(ceph_ll_write(cmount1, fh, 0, sizeof(filename), filename),
+           static_cast<int>(sizeof(filename)));
   ASSERT_EQ(ceph_ll_close(cmount1, fh), 0);
 
   /* New mount for read delegation */
@@ -352,7 +353,8 @@ TEST(LibCephFS, RecalledGetattr) {
   ASSERT_EQ(ceph_ll_lookup(cmount2, root, filename, &file, &stx, 0, 0, perms), 0);
 
   ASSERT_EQ(ceph_ll_open(cmount2, file, O_WRONLY, &fh, perms), 0);
-  ASSERT_EQ(ceph_ll_write(cmount2, fh, 0, sizeof(filename), filename), sizeof(filename));
+  ASSERT_EQ(ceph_ll_write(cmount2, fh, 0, sizeof(filename), filename),
+           static_cast<int>(sizeof(filename)));
   ASSERT_EQ(ceph_ll_close(cmount2, fh), 0);
 
   ASSERT_EQ(ceph_ll_open(cmount2, file, O_RDONLY, &fh, perms), 0);
@@ -360,7 +362,8 @@ TEST(LibCephFS, RecalledGetattr) {
   /* Break delegation */
   std::atomic_bool recalled(false);
   ASSERT_EQ(ceph_ll_delegation(cmount2, fh, CEPH_DELEGATION_RD, dummy_deleg_cb, &recalled), 0);
-  ASSERT_EQ(ceph_ll_read(cmount2, fh, 0, sizeof(filename), filename), sizeof(filename));
+  ASSERT_EQ(ceph_ll_read(cmount2, fh, 0, sizeof(filename), filename),
+           static_cast<int>(sizeof(filename)));
   ASSERT_EQ(ceph_ll_getattr(cmount2, file, &stx, CEPH_STATX_ALL_STATS, 0, perms), 0);
   std::atomic_bool opened(false);
   std::thread breaker1(open_breaker_func, cmount1, filename, O_WRONLY, &opened);
index fa1cc63bcb82cc09f2c9bbc42ba9c72d26722e98..9c6a1b3d65080ab6f5e76f280bdc91458e92822e 100644 (file)
@@ -631,13 +631,13 @@ TEST(LibCephFS, StatDirNlink) {
   ASSERT_GT(fd, 0);
   struct ceph_statx stx;
   ASSERT_EQ(ceph_fstatx(cmount, fd, &stx, CEPH_STATX_NLINK, AT_SYMLINK_NOFOLLOW), 0);
-  ASSERT_EQ(stx.stx_nlink, 2);
+  ASSERT_EQ(stx.stx_nlink, 2u);
 
   {
     char test_dir2[296];
     sprintf(test_dir2, "%s/.", test_dir1);
     ASSERT_EQ(ceph_statx(cmount, test_dir2, &stx, CEPH_STATX_NLINK, AT_SYMLINK_NOFOLLOW), 0);
-    ASSERT_EQ(stx.stx_nlink, 2);
+    ASSERT_EQ(stx.stx_nlink, 2u);
   }
 
   {
@@ -645,33 +645,33 @@ TEST(LibCephFS, StatDirNlink) {
     sprintf(test_dir2, "%s/1", test_dir1);
     ASSERT_EQ(ceph_mkdir(cmount, test_dir2, 0700), 0);
     ASSERT_EQ(ceph_statx(cmount, test_dir2, &stx, CEPH_STATX_NLINK, AT_SYMLINK_NOFOLLOW), 0);
-    ASSERT_EQ(stx.stx_nlink, 2);
+    ASSERT_EQ(stx.stx_nlink, 2u);
       ASSERT_EQ(ceph_statx(cmount, test_dir1, &stx, CEPH_STATX_NLINK, AT_SYMLINK_NOFOLLOW), 0);
-      ASSERT_EQ(stx.stx_nlink, 3);
+      ASSERT_EQ(stx.stx_nlink, 3u);
     sprintf(test_dir2, "%s/2", test_dir1);
     ASSERT_EQ(ceph_mkdir(cmount, test_dir2, 0700), 0);
       ASSERT_EQ(ceph_statx(cmount, test_dir1, &stx, CEPH_STATX_NLINK, AT_SYMLINK_NOFOLLOW), 0);
-      ASSERT_EQ(stx.stx_nlink, 4);
+      ASSERT_EQ(stx.stx_nlink, 4u);
     sprintf(test_dir2, "%s/1/1", test_dir1);
     ASSERT_EQ(ceph_mkdir(cmount, test_dir2, 0700), 0);
       ASSERT_EQ(ceph_statx(cmount, test_dir1, &stx, CEPH_STATX_NLINK, AT_SYMLINK_NOFOLLOW), 0);
-      ASSERT_EQ(stx.stx_nlink, 4);
+      ASSERT_EQ(stx.stx_nlink, 4u);
     ASSERT_EQ(ceph_rmdir(cmount, test_dir2), 0);
       ASSERT_EQ(ceph_statx(cmount, test_dir1, &stx, CEPH_STATX_NLINK, AT_SYMLINK_NOFOLLOW), 0);
-      ASSERT_EQ(stx.stx_nlink, 4);
+      ASSERT_EQ(stx.stx_nlink, 4u);
     sprintf(test_dir2, "%s/1", test_dir1);
     ASSERT_EQ(ceph_rmdir(cmount, test_dir2), 0);
       ASSERT_EQ(ceph_statx(cmount, test_dir1, &stx, CEPH_STATX_NLINK, AT_SYMLINK_NOFOLLOW), 0);
-      ASSERT_EQ(stx.stx_nlink, 3);
+      ASSERT_EQ(stx.stx_nlink, 3u);
     sprintf(test_dir2, "%s/2", test_dir1);
     ASSERT_EQ(ceph_rmdir(cmount, test_dir2), 0);
       ASSERT_EQ(ceph_statx(cmount, test_dir1, &stx, CEPH_STATX_NLINK, AT_SYMLINK_NOFOLLOW), 0);
-      ASSERT_EQ(stx.stx_nlink, 2);
+      ASSERT_EQ(stx.stx_nlink, 2u);
   }
 
   ASSERT_EQ(ceph_rmdir(cmount, test_dir1), 0);
   ASSERT_EQ(ceph_fstatx(cmount, fd, &stx, CEPH_STATX_NLINK, AT_SYMLINK_NOFOLLOW), 0);
-  ASSERT_EQ(stx.stx_nlink, 0);
+  ASSERT_EQ(stx.stx_nlink, 0u);
 
   ceph_close(cmount, fd);
 
index f718cbb10084d22ca7263bb014d84d41023935a7..d3d8e772cbcfe96e213b81b6cc0bae44c366758b 100644 (file)
@@ -648,8 +648,8 @@ TEST_F(CReadOpsTest, Omap) {
   rados_release_read_op(rop);
   EXPECT_EQ(0, r_vals);
   EXPECT_EQ(0, r_keys);
-  EXPECT_EQ(1, rados_omap_iter_size(iter_vals));
-  EXPECT_EQ(1, rados_omap_iter_size(iter_keys));
+  EXPECT_EQ(1u, rados_omap_iter_size(iter_vals));
+  EXPECT_EQ(1u, rados_omap_iter_size(iter_keys));
 
   compare_omap_vals(&keys[2], &vals[2], &lens[2], 1, iter_vals);
   compare_omap_vals(&keys[2], &vals[0], &lens[0], 1, iter_keys);
index d872f634ac44c095ee69cd7ee25442c778248bfb..4a777934af560b48e8c6cf332e5cb4f7ccc5288e 100644 (file)
@@ -3252,7 +3252,7 @@ TEST_F(LibRadosTwoPoolsPP, ManifestRefRead) {
     } catch (buffer::error& err) {
       ASSERT_TRUE(0);
     }
-    ASSERT_EQ(1, read_ret.refs.size());
+    ASSERT_EQ(1u, read_ret.refs.size());
   }
 
   // wait for maps to settle before next test
@@ -3337,7 +3337,7 @@ TEST_F(LibRadosTwoPoolsPP, ManifestUnset) {
     } catch (buffer::error& err) {
       ASSERT_TRUE(0);
     }
-    ASSERT_EQ(1, read_ret.refs.size());
+    ASSERT_EQ(1u, read_ret.refs.size());
   }
   // chunk's refcount 
   {
@@ -3350,7 +3350,7 @@ TEST_F(LibRadosTwoPoolsPP, ManifestUnset) {
     } catch (buffer::error& err) {
       ASSERT_TRUE(0);
     }
-    ASSERT_EQ(1, read_ret.refs.size());
+    ASSERT_EQ(1u, read_ret.refs.size());
   }
 
   // unset-manifest for set-redirect
@@ -3384,7 +3384,7 @@ TEST_F(LibRadosTwoPoolsPP, ManifestUnset) {
   {
     bufferlist in, out;
     cache_ioctx.exec("bar-chunk", "cas", "chunk_read", in, out);
-    ASSERT_EQ(0, out.length());
+    ASSERT_EQ(0u, out.length());
   }
 
   // wait for maps to settle before next test
@@ -3521,7 +3521,7 @@ TEST_F(LibRadosTwoPoolsPP, ManifestDedupRefRead) {
     } catch (buffer::error& err) {
       ASSERT_TRUE(0);
     }
-    ASSERT_EQ(2, read_ret.refs.size());
+    ASSERT_EQ(2u, read_ret.refs.size());
   }
 
   // wait for maps to settle before next test
index 4ffc4d8dfb87a7d8cea0b2abe3fc60bd264fda38..f269f0ac0c85751483a6f8bd9f9a4a50e99368ee 100644 (file)
@@ -237,7 +237,7 @@ TEST_P(MessengerTest, SimpleTest) {
     cli_dispatcher.got_new = false;
   }
   ASSERT_TRUE(conn->is_connected());
-  ASSERT_EQ(1, static_cast<Session*>(conn->get_priv().get())->get_count());
+  ASSERT_EQ(1u, static_cast<Session*>(conn->get_priv().get())->get_count());
   ASSERT_TRUE(conn->peer_is_osd());
 
   // 2. test rebind port
index 9e468748d4ad2cfb12c21411ee614a8aefbbb2ba..229d793a80b2161c2cfa6160bc50132980a87628 100644 (file)
@@ -271,7 +271,7 @@ TEST_P(AllocTest, test_alloc_fragmentation)
     EXPECT_EQ(50U, uint64_t(alloc->get_fragmentation(alloc_unit) * 100));
   } else {
     // fragmentation approx = 257 intervals / 768 max intervals
-    EXPECT_EQ(33, uint64_t(alloc->get_fragmentation(alloc_unit) * 100));
+    EXPECT_EQ(33u, uint64_t(alloc->get_fragmentation(alloc_unit) * 100));
   }
 
   for (size_t i = allocated.size() / 2 + 1; i < allocated.size(); i += 2)
@@ -284,7 +284,7 @@ TEST_P(AllocTest, test_alloc_fragmentation)
   // extents that causes some minor fragmentation (minor bug or by-design behavior?).
   // Hence leaving just two 
   // digits after decimal point due to this.
-  EXPECT_EQ(0, uint64_t(alloc->get_fragmentation(alloc_unit) * 100));
+  EXPECT_EQ(0u, uint64_t(alloc->get_fragmentation(alloc_unit) * 100));
 }
 
 TEST_P(AllocTest, test_alloc_bug_24598)
index a4ef142bf76a20f28b5e6eae631bf4036e7da078..537ebc36d6dd4429ded8aa47325c15e89c1ea493 100755 (executable)
@@ -58,51 +58,51 @@ TEST(TestAllocatorLevel01, test_l1)
   ASSERT_EQ(capacity, al1.debug_get_free());
 
   auto i1 = al1.allocate_l1_cont(0x1000, 0x1000, 0, num_l1_entries);
-  ASSERT_EQ(i1.offset, 0);
-  ASSERT_EQ(i1.length, 0x1000);
+  ASSERT_EQ(i1.offset, 0u);
+  ASSERT_EQ(i1.length, 0x1000u);
   ASSERT_EQ(capacity - 0x1000, al1.debug_get_free());
 
   auto i2 = al1.allocate_l1_cont(0x1000, 0x1000, 0, num_l1_entries);
-  ASSERT_EQ(i2.offset, 0x1000);
-  ASSERT_EQ(i2.length, 0x1000);
+  ASSERT_EQ(i2.offset, 0x1000u);
+  ASSERT_EQ(i2.length, 0x1000u);
   al1.free_l1(i2);
   al1.free_l1(i1);
   i1 = al1.allocate_l1_cont(0x1000, 0x1000, 0, num_l1_entries);
-  ASSERT_EQ(i1.offset, 0);
-  ASSERT_EQ(i1.length, 0x1000);
+  ASSERT_EQ(i1.offset, 0u);
+  ASSERT_EQ(i1.length, 0x1000u);
   i2 = al1.allocate_l1_cont(0x1000, 0x1000, 0, num_l1_entries);
-  ASSERT_EQ(i2.offset, 0x1000);
-  ASSERT_EQ(i2.length, 0x1000);
+  ASSERT_EQ(i2.offset, 0x1000u);
+  ASSERT_EQ(i2.length, 0x1000u);
   al1.free_l1(i1);
   al1.free_l1(i2);
 
   i1 = al1.allocate_l1_cont(0x2000, 0x1000, 0, num_l1_entries);
-  ASSERT_EQ(i1.offset, 0);
-  ASSERT_EQ(i1.length, 0x2000);
+  ASSERT_EQ(i1.offset, 0u);
+  ASSERT_EQ(i1.length, 0x2000u);
 
   i2 = al1.allocate_l1_cont(0x3000, 0x1000, 0, num_l1_entries);
-  ASSERT_EQ(i2.offset, 0x2000);
-  ASSERT_EQ(i2.length, 0x3000);
+  ASSERT_EQ(i2.offset, 0x2000u);
+  ASSERT_EQ(i2.length, 0x3000u);
 
   al1.free_l1(i1);
   al1.free_l1(i2);
 
   i1 = al1.allocate_l1_cont(0x2000, 0x1000, 0, num_l1_entries);
-  ASSERT_EQ(i1.offset, 0);
-  ASSERT_EQ(i1.length, 0x2000);
+  ASSERT_EQ(i1.offset, 0u);
+  ASSERT_EQ(i1.length, 0x2000u);
 
   i2 = al1.allocate_l1_cont(2 * 1024 * 1024, 0x1000, 0, num_l1_entries);
-  ASSERT_EQ(i2.offset, 2 * 1024 * 1024);
-  ASSERT_EQ(i2.length, 2 * 1024 * 1024);
+  ASSERT_EQ(i2.offset, 2u * 1024u * 1024u);
+  ASSERT_EQ(i2.length, 2u * 1024u * 1024u);
 
   al1.free_l1(i1);
   i1 = al1.allocate_l1_cont(1024 * 1024, 0x1000, 0, num_l1_entries);
-  ASSERT_EQ(i1.offset, 0);
-  ASSERT_EQ(i1.length, 1024 * 1024);
+  ASSERT_EQ(i1.offset, 0u);
+  ASSERT_EQ(i1.length, 1024u * 1024u);
 
   auto i3 = al1.allocate_l1_cont(1024 * 1024 + 0x1000, 0x1000, 0, num_l1_entries);
-  ASSERT_EQ(i3.offset, 2 * 2 * 1024 * 1024);
-  ASSERT_EQ(i3.length, 1024 * 1024 + 0x1000);
+  ASSERT_EQ(i3.offset, 2u * 2u * 1024u * 1024u);
+  ASSERT_EQ(i3.length, 1024u * 1024u + 0x1000u);
 
   // here we have the following layout:
   // Alloc: 0~1M, 2M~2M, 4M~1M+4K
@@ -114,14 +114,14 @@ TEST(TestAllocatorLevel01, test_l1)
   al1.free_l1(i4);
 
   i4 = al1.allocate_l1_cont(1024 * 1024 - 0x1000, 0x1000, 0, num_l1_entries);
-  ASSERT_EQ(i4.offset, 5 * 1024 * 1024 + 0x1000);
-  ASSERT_EQ(i4.length, 1024 * 1024 - 0x1000);
+  ASSERT_EQ(i4.offset, 5u * 1024u * 1024u + 0x1000u);
+  ASSERT_EQ(i4.length, 1024u * 1024u - 0x1000u);
   al1.free_l1(i4);
 
   i4 = al1.allocate_l1_cont(1024 * 1024 + 0x1000, 0x1000, 0, num_l1_entries);
-  ASSERT_EQ(i4.offset, 6 * 1024 * 1024);
+  ASSERT_EQ(i4.offset, 6u * 1024u * 1024u);
   //ASSERT_EQ(i4.offset, 5 * 1024 * 1024 + 0x1000);
-  ASSERT_EQ(i4.length, 1024 * 1024 + 0x1000);
+  ASSERT_EQ(i4.length, 1024u * 1024u + 0x1000u);
 
   al1.free_l1(i1);
   al1.free_l1(i2);
@@ -129,37 +129,37 @@ TEST(TestAllocatorLevel01, test_l1)
   al1.free_l1(i4);
 
   i1 = al1.allocate_l1_cont(1024 * 1024, 0x1000, 0, num_l1_entries);
-  ASSERT_EQ(i1.offset, 0);
-  ASSERT_EQ(i1.length, 1024 * 1024);
+  ASSERT_EQ(i1.offset, 0u);
+  ASSERT_EQ(i1.length, 1024u * 1024u);
 
   i2 = al1.allocate_l1_cont(1024 * 1024, 0x1000, 0, num_l1_entries);
-  ASSERT_EQ(i2.offset, 1 * 1024 * 1024);
-  ASSERT_EQ(i2.length, 1024 * 1024 );
+  ASSERT_EQ(i2.offset, 1u * 1024u * 1024u);
+  ASSERT_EQ(i2.length, 1024u * 1024u);
 
   i3 = al1.allocate_l1_cont(512 * 1024, 0x1000, 0, num_l1_entries);
-  ASSERT_EQ(i3.offset, 2 * 1024 * 1024);
-  ASSERT_EQ(i3.length, 512 * 1024);
+  ASSERT_EQ(i3.offset, 2u * 1024u * 1024u);
+  ASSERT_EQ(i3.length, 512u * 1024u);
 
   i4 = al1.allocate_l1_cont(1536 * 1024, 0x1000, 0, num_l1_entries);
-  ASSERT_EQ(i4.offset, (2 * 1024 + 512) * 1024 );
-  ASSERT_EQ(i4.length, 1536 * 1024);
+  ASSERT_EQ(i4.offset, (2u * 1024u + 512u) * 1024u);
+  ASSERT_EQ(i4.length, 1536u * 1024u);
   // making a hole 1.5 Mb length
   al1.free_l1(i2);
   al1.free_l1(i3);
   // and trying to fill it
   i2 = al1.allocate_l1_cont(1536 * 1024, 0x1000, 0, num_l1_entries);
-  ASSERT_EQ(i2.offset, 1024 * 1024);
-  ASSERT_EQ(i2.length, 1536 * 1024);
+  ASSERT_EQ(i2.offset, 1024u * 1024u);
+  ASSERT_EQ(i2.length, 1536u * 1024u);
 
   al1.free_l1(i2);
   // and trying to fill it partially
   i2 = al1.allocate_l1_cont(1528 * 1024, 0x1000, 0, num_l1_entries);
-  ASSERT_EQ(i2.offset, 1024 * 1024);
-  ASSERT_EQ(i2.length, 1528 * 1024);
+  ASSERT_EQ(i2.offset, 1024u * 1024u);
+  ASSERT_EQ(i2.length, 1528u * 1024u);
 
   i3 = al1.allocate_l1_cont(8 * 1024, 0x1000, 0, num_l1_entries);
-  ASSERT_EQ(i3.offset, 2552 * 1024);
-  ASSERT_EQ(i3.length, 8 * 1024);
+  ASSERT_EQ(i3.offset, 2552u * 1024u);
+  ASSERT_EQ(i3.length, 8u * 1024u);
 
   al1.free_l1(i2);
   // here we have the following layout:
@@ -167,8 +167,8 @@ TEST(TestAllocatorLevel01, test_l1)
   // Free: 1M~1528K, 4M ~...
   //
   i2 = al1.allocate_l1_cont(1536 * 1024, 0x1000, 0, num_l1_entries);
-  ASSERT_EQ(i2.offset, 4 * 1024 * 1024);
-  ASSERT_EQ(i2.length, 1536 * 1024);
+  ASSERT_EQ(i2.offset, 4u * 1024u * 1024u);
+  ASSERT_EQ(i2.length, 1536u * 1024u);
 
   al1.free_l1(i1);
   al1.free_l1(i2);
@@ -181,10 +181,10 @@ TEST(TestAllocatorLevel01, test_l1)
     ASSERT_EQ(i1.offset, i);
     ASSERT_EQ(i1.length, _2m);
   }
-  ASSERT_EQ(0, al1.debug_get_free());
+  ASSERT_EQ(0u, al1.debug_get_free());
   i2 = al1.allocate_l1_cont(_2m, _2m, 0, num_l1_entries);
-  ASSERT_EQ(i2.length, 0);
-  ASSERT_EQ(0, al1.debug_get_free());
+  ASSERT_EQ(i2.length, 0u);
+  ASSERT_EQ(0u, al1.debug_get_free());
 
   al1.free_l1(i1);
   i2 = al1.allocate_l1_cont(_2m, _2m, 0, num_l1_entries);
@@ -195,17 +195,17 @@ TEST(TestAllocatorLevel01, test_l1)
   ASSERT_EQ(i2.length, _1m);
 
   i3 = al1.allocate_l1_cont(_2m, _2m, 0, num_l1_entries);
-  ASSERT_EQ(i3.length, 0);
+  ASSERT_EQ(i3.length, 0u);
 
   i3 = al1.allocate_l1_cont(_2m, _1m, 0, num_l1_entries);
   ASSERT_EQ(i3.length, _1m);
 
   i4 = al1.allocate_l1_cont(_2m, _1m, 0, num_l1_entries);
-  ASSERT_EQ(i4.length, 0);
+  ASSERT_EQ(i4.length, 0u);
 
   al1.free_l1(i2);
   i2 = al1.allocate_l1_cont(_2m, _2m, 0, num_l1_entries);
-  ASSERT_EQ(i2.length, 0);
+  ASSERT_EQ(i2.length, 0u);
 
   i2 = al1.allocate_l1_cont(_2m, 0x1000, 0, num_l1_entries);
   ASSERT_EQ(i2.length, _1m);
@@ -218,22 +218,22 @@ TEST(TestAllocatorLevel01, test_l1)
   i2 = al1.allocate_l1_cont(0x1000, 0x1000, 0, num_l1_entries);
   i3 = al1.allocate_l1_cont(0x1000, 0x1000, 0, num_l1_entries);
   i4 = al1.allocate_l1_cont(0x1000, 0x1000, 0, num_l1_entries);
-  ASSERT_EQ(0, al1.debug_get_free());
+  ASSERT_EQ(0u, al1.debug_get_free());
 
   al1.free_l1(i2);
   al1.free_l1(i4);
 
   i2 = al1.allocate_l1_cont(0x4000, 0x2000, 0, num_l1_entries);
-  ASSERT_EQ(i2.length, 0);
+  ASSERT_EQ(i2.length, 0u);
   i2 = al1.allocate_l1_cont(0x4000, 0x1000, 0, num_l1_entries);
-  ASSERT_EQ(i2.length, 0x1000);
+  ASSERT_EQ(i2.length, 0x1000u);
 
   al1.free_l1(i3);
   i3 = al1.allocate_l1_cont(0x6000, 0x3000, 0, num_l1_entries);
-  ASSERT_EQ(i3.length, 0);
+  ASSERT_EQ(i3.length, 0u);
   i3 = al1.allocate_l1_cont(0x6000, 0x1000, 0, num_l1_entries);
-  ASSERT_EQ(i3.length, 0x2000);
-  ASSERT_EQ(0, al1.debug_get_free());
+  ASSERT_EQ(i3.length, 0x2000u);
+  ASSERT_EQ(0u, al1.debug_get_free());
 
   std::cout << "Done L1" << std::endl;
 }
@@ -249,48 +249,48 @@ TEST(TestAllocatorLevel01, test_l2)
   uint64_t allocated1 = 0;
   interval_vector_t a1;
   al2.allocate_l2(0x2000, 0x2000, &allocated1, &a1);
-  ASSERT_EQ(allocated1, 0x2000);
-  ASSERT_EQ(a1[0].offset, 0);
-  ASSERT_EQ(a1[0].length, 0x2000);
+  ASSERT_EQ(allocated1, 0x2000u);
+  ASSERT_EQ(a1[0].offset, 0u);
+  ASSERT_EQ(a1[0].length, 0x2000u);
 
   // limit query range in debug_get_free for the sake of performance
-  ASSERT_EQ(0x2000, al2.debug_get_allocated(0, 1));
-  ASSERT_EQ(0, al2.debug_get_allocated(1, 2));
+  ASSERT_EQ(0x2000u, al2.debug_get_allocated(0, 1));
+  ASSERT_EQ(0u, al2.debug_get_allocated(1, 2));
 
   uint64_t allocated2 = 0;
   interval_vector_t a2;
   al2.allocate_l2(0x2000, 0x2000, &allocated2, &a2);
-  ASSERT_EQ(allocated2, 0x2000);
-  ASSERT_EQ(a2[0].offset, 0x2000);
-  ASSERT_EQ(a2[0].length, 0x2000);
+  ASSERT_EQ(allocated2, 0x2000u);
+  ASSERT_EQ(a2[0].offset, 0x2000u);
+  ASSERT_EQ(a2[0].length, 0x2000u);
   // limit query range in debug_get_free for the sake of performance
-  ASSERT_EQ(0x4000, al2.debug_get_allocated(0, 1));
-  ASSERT_EQ(0, al2.debug_get_allocated(1, 2));
+  ASSERT_EQ(0x4000u, al2.debug_get_allocated(0, 1));
+  ASSERT_EQ(0u, al2.debug_get_allocated(1, 2));
 
   al2.free_l2(a1);
 
   allocated2 = 0;
   a2.clear();
   al2.allocate_l2(0x1000, 0x1000, &allocated2, &a2);
-  ASSERT_EQ(allocated2, 0x1000);
-  ASSERT_EQ(a2[0].offset, 0x0000);
-  ASSERT_EQ(a2[0].length, 0x1000);
+  ASSERT_EQ(allocated2, 0x1000u);
+  ASSERT_EQ(a2[0].offset, 0x0000u);
+  ASSERT_EQ(a2[0].length, 0x1000u);
   // limit query range in debug_get_free for the sake of performance
-  ASSERT_EQ(0x3000, al2.debug_get_allocated(0, 1));
-  ASSERT_EQ(0, al2.debug_get_allocated(1, 2));
+  ASSERT_EQ(0x3000u, al2.debug_get_allocated(0, 1));
+  ASSERT_EQ(0u, al2.debug_get_allocated(1, 2));
 
   uint64_t allocated3 = 0;
   interval_vector_t a3;
   al2.allocate_l2(0x2000, 0x1000, &allocated3, &a3);
-  ASSERT_EQ(allocated3, 0x2000);
-  ASSERT_EQ(a3.size(), 2);
-  ASSERT_EQ(a3[0].offset, 0x1000);
-  ASSERT_EQ(a3[0].length, 0x1000);
-  ASSERT_EQ(a3[1].offset, 0x4000);
-  ASSERT_EQ(a3[1].length, 0x1000);
+  ASSERT_EQ(allocated3, 0x2000u);
+  ASSERT_EQ(a3.size(), 2u);
+  ASSERT_EQ(a3[0].offset, 0x1000u);
+  ASSERT_EQ(a3[0].length, 0x1000u);
+  ASSERT_EQ(a3[1].offset, 0x4000u);
+  ASSERT_EQ(a3[1].length, 0x1000u);
   // limit query range in debug_get_free for the sake of performance
-  ASSERT_EQ(0x5000, al2.debug_get_allocated(0, 1));
-  ASSERT_EQ(0, al2.debug_get_allocated(1, 2));
+  ASSERT_EQ(0x5000u, al2.debug_get_allocated(0, 1));
+  ASSERT_EQ(0u, al2.debug_get_allocated(1, 2));
   {
     interval_vector_t r;
     r.emplace_back(0x0, 0x5000);
@@ -300,8 +300,8 @@ TEST(TestAllocatorLevel01, test_l2)
   a3.clear();
   allocated3 = 0;
   al2.allocate_l2(_1m, _1m, &allocated3, &a3);
-  ASSERT_EQ(a3.size(), 1);
-  ASSERT_EQ(a3[0].offset, 0);
+  ASSERT_EQ(a3.size(), 1u);
+  ASSERT_EQ(a3[0].offset, 0u);
   ASSERT_EQ(a3[0].length, _1m);
 
   al2.free_l2(a3);
@@ -309,8 +309,8 @@ TEST(TestAllocatorLevel01, test_l2)
   a3.clear();
   allocated3 = 0;
   al2.allocate_l2(4 * _1m, _1m, &allocated3, &a3);
-  ASSERT_EQ(a3.size(), 1);
-  ASSERT_EQ(a3[0].offset, 0);
+  ASSERT_EQ(a3.size(), 1u);
+  ASSERT_EQ(a3[0].offset, 0u);
   ASSERT_EQ(a3[0].length, 4 * _1m);
 
   al2.free_l2(a3);
@@ -320,9 +320,9 @@ TEST(TestAllocatorLevel01, test_l2)
     uint64_t allocated4 = 0;
     interval_vector_t a4;
     al2.allocate_l2(0x1000, 0x1000, &allocated4, &a4);
-    ASSERT_EQ(a4.size(), 1);
+    ASSERT_EQ(a4.size(), 1u);
     ASSERT_EQ(a4[0].offset, i);
-    ASSERT_EQ(a4[0].length, 0x1000);
+    ASSERT_EQ(a4[0].length, 0x1000u);
     if (0 == (i % (1 * 1024 * _1m))) {
       std::cout << "alloc1 " << i / 1024 / 1024 << " mb of "
         << capacity / 1024 / 1024 << std::endl;
@@ -343,7 +343,7 @@ TEST(TestAllocatorLevel01, test_l2)
   }
 #endif
 
-  ASSERT_EQ(0, al2.debug_get_free());
+  ASSERT_EQ(0u, al2.debug_get_free());
   for (uint64_t i = 0; i < capacity; i += _1m) {
     interval_vector_t r;
     r.emplace_back(interval_t(i, _1m));
@@ -359,7 +359,7 @@ TEST(TestAllocatorLevel01, test_l2)
     uint64_t allocated4 = 0;
     interval_vector_t a4;
     al2.allocate_l2(_1m, _1m, &allocated4, &a4);
-    ASSERT_EQ(a4.size(), 1);
+    ASSERT_EQ(a4.size(), 1u);
     ASSERT_EQ(allocated4, _1m);
     ASSERT_EQ(a4[0].offset, i);
     ASSERT_EQ(a4[0].length, _1m);
@@ -368,13 +368,13 @@ TEST(TestAllocatorLevel01, test_l2)
         << capacity / 1024 / 1024 << std::endl;
     }
   }
-  ASSERT_EQ(0, al2.debug_get_free());
+  ASSERT_EQ(0u, al2.debug_get_free());
   uint64_t allocated4 = 0;
   interval_vector_t a4;
   al2.allocate_l2(_1m, _1m, &allocated4, &a4);
-  ASSERT_EQ(a4.size(), 0);
+  ASSERT_EQ(a4.size(), 0u);
   al2.allocate_l2(0x1000, 0x1000, &allocated4, &a4);
-  ASSERT_EQ(a4.size(), 0);
+  ASSERT_EQ(a4.size(), 0u);
 
   for (uint64_t i = 0; i < capacity; i += 0x2000) {
     interval_vector_t r;
@@ -389,7 +389,7 @@ TEST(TestAllocatorLevel01, test_l2)
 
   // unable to allocate due to fragmentation
   al2.allocate_l2(_1m, _1m, &allocated4, &a4);
-  ASSERT_EQ(a4.size(), 0);
+  ASSERT_EQ(a4.size(), 0u);
 
   for (uint64_t i = 0; i < capacity; i += 2 * _1m) {
     a4.clear();
@@ -398,13 +398,13 @@ TEST(TestAllocatorLevel01, test_l2)
     ASSERT_EQ(a4.size(), _1m / 0x1000);
     ASSERT_EQ(allocated4, _1m);
     ASSERT_EQ(a4[0].offset, i);
-    ASSERT_EQ(a4[0].length, 0x1000);
+    ASSERT_EQ(a4[0].length, 0x1000u);
     if (0 == (i % (1 * 1024 * _1m))) {
       std::cout << "alloc3 " << i / 1024 / 1024 << " mb of "
         << capacity / 1024 / 1024 << std::endl;
     }
   }
-  ASSERT_EQ(0, al2.debug_get_free());
+  ASSERT_EQ(0u, al2.debug_get_free());
 
   std::cout << "Done L2" << std::endl;
 }
@@ -421,15 +421,15 @@ TEST(TestAllocatorLevel01, test_l2_huge)
     uint64_t allocated4 = 0;
     interval_vector_t a4;
     al2.allocate_l2(0x1000, 0x1000, &allocated4, &a4);
-    ASSERT_EQ(a4.size(), 1);
-    ASSERT_EQ(allocated4, 0x1000);
+    ASSERT_EQ(a4.size(), 1u);
+    ASSERT_EQ(allocated4, 0x1000u);
     ASSERT_EQ(a4[0].offset, i);
-    ASSERT_EQ(a4[0].length, 0x1000);
+    ASSERT_EQ(a4[0].length, 0x1000u);
 
     allocated4 = 0;
     a4.clear();
     al2.allocate_l2(_1m - 0x1000, 0x1000, &allocated4, &a4);
-    ASSERT_EQ(a4.size(), 1);
+    ASSERT_EQ(a4.size(), 1u);
     ASSERT_EQ(allocated4, _1m - 0x1000);
     ASSERT_EQ(a4[0].offset, i + 0x1000);
     ASSERT_EQ(a4[0].length, _1m - 0x1000);
@@ -454,7 +454,7 @@ TEST(TestAllocatorLevel01, test_l2_huge)
       uint64_t allocated = 0;
       interval_vector_t a;
       al2.allocate_l2(0x2000, 0x2000, &allocated, &a);
-      ASSERT_EQ(a.size(), 0);
+      ASSERT_EQ(a.size(), 0u);
     }
     std::cout << "End try in " << time(NULL) - t << " seconds" << std::endl;
   }
@@ -465,7 +465,7 @@ TEST(TestAllocatorLevel01, test_l2_huge)
       uint64_t allocated = 0;
       interval_vector_t a;
       al2.allocate_l2(_2m, _2m, &allocated, &a);
-      ASSERT_EQ(a.size(), 0);
+      ASSERT_EQ(a.size(), 0u);
     }
     std::cout << "End try in " << time(NULL) - t << " seconds" << std::endl;
   }
@@ -487,7 +487,7 @@ TEST(TestAllocatorLevel01, test_l2_unaligned)
       uint64_t allocated4 = 0;
       interval_vector_t a4;
       al2.allocate_l2(_1m / 2, _1m / 2, &allocated4, &a4);
-      ASSERT_EQ(a4.size(), 1);
+      ASSERT_EQ(a4.size(), 1u);
       ASSERT_EQ(allocated4, _1m / 2);
       ASSERT_EQ(a4[0].offset, i);
       ASSERT_EQ(a4[0].length, _1m / 2);
@@ -496,13 +496,13 @@ TEST(TestAllocatorLevel01, test_l2_unaligned)
           << capacity / 1024 / 1024 << std::endl;
       }
     }
-    ASSERT_EQ(0, al2.debug_get_free());
+    ASSERT_EQ(0u, al2.debug_get_free());
     {
       // no space to allocate
       uint64_t allocated4 = 0;
       interval_vector_t a4;
       al2.allocate_l2(0x1000, 0x1000, &allocated4, &a4);
-      ASSERT_EQ(a4.size(), 0);
+      ASSERT_EQ(a4.size(), 0u);
     }
   }
   {
@@ -514,7 +514,7 @@ TEST(TestAllocatorLevel01, test_l2_unaligned)
       uint64_t allocated4 = 0;
       interval_vector_t a4;
       al2.allocate_l2(_1m / 2, _1m / 2, &allocated4, &a4);
-      ASSERT_EQ(a4.size(), 1);
+      ASSERT_EQ(a4.size(), 1u);
       ASSERT_EQ(allocated4, _1m / 2);
       ASSERT_EQ(a4[0].offset, i);
       ASSERT_EQ(a4[0].length, _1m / 2);
@@ -523,13 +523,13 @@ TEST(TestAllocatorLevel01, test_l2_unaligned)
           << capacity / 1024 / 1024 << std::endl;
       }
     }
-    ASSERT_EQ(0, al2.debug_get_free());
+    ASSERT_EQ(0u, al2.debug_get_free());
     {
       // no space to allocate
       uint64_t allocated4 = 0;
       interval_vector_t a4;
       al2.allocate_l2(0x1000, 0x1000, &allocated4, &a4);
-      ASSERT_EQ(a4.size(), 0);
+      ASSERT_EQ(a4.size(), 0u);
     }
   }
 
@@ -542,18 +542,18 @@ TEST(TestAllocatorLevel01, test_l2_unaligned)
       uint64_t allocated4 = 0;
       interval_vector_t a4;
       al2.allocate_l2(0x1000, 0x1000, &allocated4, &a4);
-      ASSERT_EQ(a4.size(), 1);
-      ASSERT_EQ(allocated4, 0x1000);
+      ASSERT_EQ(a4.size(), 1u);
+      ASSERT_EQ(allocated4, 0x1000u);
       ASSERT_EQ(a4[0].offset, i);
-      ASSERT_EQ(a4[0].length, 0x1000);
+      ASSERT_EQ(a4[0].length, 0x1000u);
     }
-    ASSERT_EQ(0, al2.debug_get_free());
+    ASSERT_EQ(0u, al2.debug_get_free());
     {
       // no space to allocate
       uint64_t allocated4 = 0;
       interval_vector_t a4;
       al2.allocate_l2(0x1000, 0x1000, &allocated4, &a4);
-      ASSERT_EQ(a4.size(), 0);
+      ASSERT_EQ(a4.size(), 0u);
     }
   }
   {
@@ -565,18 +565,18 @@ TEST(TestAllocatorLevel01, test_l2_unaligned)
       uint64_t allocated4 = 0;
       interval_vector_t a4;
       al2.allocate_l2(0x1000, 0x1000, &allocated4, &a4);
-      ASSERT_EQ(a4.size(), 1);
-      ASSERT_EQ(allocated4, 0x1000);
+      ASSERT_EQ(a4.size(), 1u);
+      ASSERT_EQ(allocated4, 0x1000u);
       ASSERT_EQ(a4[0].offset, i);
-      ASSERT_EQ(a4[0].length, 0x1000);
+      ASSERT_EQ(a4[0].length, 0x1000u);
     }
-    ASSERT_EQ(0, al2.debug_get_free());
+    ASSERT_EQ(0u, al2.debug_get_free());
     {
       // no space to allocate
       uint64_t allocated4 = 0;
       interval_vector_t a4;
       al2.allocate_l2(0x1000, 0x1000, &allocated4, &a4);
-      ASSERT_EQ(a4.size(), 0);
+      ASSERT_EQ(a4.size(), 0u);
     }
   }
 
@@ -595,7 +595,7 @@ TEST(TestAllocatorLevel01, test_l2_contiguous_alignment)
       uint64_t allocated4 = 0;
       interval_vector_t a4;
       al2.allocate_l2(_1m, _1m, &allocated4, &a4);
-      ASSERT_EQ(a4.size(), 1);
+      ASSERT_EQ(a4.size(), 1u);
       ASSERT_EQ(allocated4, _1m);
       ASSERT_EQ(a4[0].offset, i);
       ASSERT_EQ(a4[0].length, _1m);
@@ -613,17 +613,17 @@ TEST(TestAllocatorLevel01, test_l2_contiguous_alignment)
       uint64_t allocated4 = 0;
       interval_vector_t a4;
       al2.allocate_l2(0x1000, 0x1000, &allocated4, &a4);
-      ASSERT_EQ(a4.size(), 1);
-      ASSERT_EQ(allocated4, 0x1000);
-      ASSERT_EQ(a4[0].offset, 0);
-      ASSERT_EQ(a4[0].length, 0x1000);
+      ASSERT_EQ(a4.size(), 1u);
+      ASSERT_EQ(allocated4, 0x1000u);
+      ASSERT_EQ(a4[0].offset, 0u);
+      ASSERT_EQ(a4[0].length, 0x1000u);
     }
     {
       // allocate 1M - should go to the second 1M chunk
       uint64_t allocated4 = 0;
       interval_vector_t a4;
       al2.allocate_l2(_1m, _1m, &allocated4, &a4);
-      ASSERT_EQ(a4.size(), 1);
+      ASSERT_EQ(a4.size(), 1u);
       ASSERT_EQ(allocated4, _1m);
       ASSERT_EQ(a4[0].offset, _1m);
       ASSERT_EQ(a4[0].length, _1m);
@@ -633,10 +633,10 @@ TEST(TestAllocatorLevel01, test_l2_contiguous_alignment)
       uint64_t allocated4 = 0;
       interval_vector_t a4;
       al2.allocate_l2(0x2000, 0x1000, &allocated4, &a4);
-      ASSERT_EQ(a4.size(), 1);
-      ASSERT_EQ(allocated4, 0x2000);
-      ASSERT_EQ(a4[0].offset, 0x1000);
-      ASSERT_EQ(a4[0].length, 0x2000);
+      ASSERT_EQ(a4.size(), 1u);
+      ASSERT_EQ(allocated4, 0x2000u);
+      ASSERT_EQ(a4[0].offset, 0x1000u);
+      ASSERT_EQ(a4[0].length, 0x2000u);
     }
     {
       // release just allocated 1M
@@ -649,7 +649,7 @@ TEST(TestAllocatorLevel01, test_l2_contiguous_alignment)
       uint64_t allocated4 = 0;
       interval_vector_t a4;
       al2.allocate_l2(3 * _1m, _1m, &allocated4, &a4);
-      ASSERT_EQ(a4.size(), 2);
+      ASSERT_EQ(a4.size(), 2u);
       ASSERT_EQ(allocated4, 3 * _1m);
       ASSERT_EQ(a4[0].offset, _1m);
       ASSERT_EQ(a4[0].length, _1m);
@@ -675,7 +675,7 @@ TEST(TestAllocatorLevel01, test_l2_contiguous_alignment)
       uint64_t allocated4 = 0;
       interval_vector_t a4;
       al2.allocate_l2(2 * _1m, _1m / 2, &allocated4, &a4);
-      ASSERT_EQ(a4.size(), 3);
+      ASSERT_EQ(a4.size(), 3u);
       ASSERT_EQ(allocated4, 2 * _1m);
       ASSERT_EQ(a4[0].offset, _1m / 2);
       ASSERT_EQ(a4[0].length, _1m / 2);
@@ -701,7 +701,7 @@ TEST(TestAllocatorLevel01, test_l2_contiguous_alignment)
       uint64_t allocated4 = 0;
       interval_vector_t a4;
       al2.allocate_l2(132 * _1m, 4 * _1m , &allocated4, &a4);
-      ASSERT_EQ(a4.size(), 1);
+      ASSERT_EQ(a4.size(), 1u);
       ASSERT_EQ(a4[0].offset, capacity / 2);
       ASSERT_EQ(a4[0].length, 132 * _1m);
     }
@@ -723,8 +723,8 @@ TEST(TestAllocatorLevel01, test_l2_contiguous_alignment)
       uint64_t allocated4 = 0;
       interval_vector_t a4;
       al2.allocate_l2(132 * _1m, 2 * _1m , &allocated4, &a4);
-      ASSERT_EQ(a4.size(), 2);
-      ASSERT_EQ(a4[0].offset, 0);
+      ASSERT_EQ(a4.size(), 2u);
+      ASSERT_EQ(a4[0].offset, 0u);
       ASSERT_EQ(a4[0].length, 2 * _1m);
       ASSERT_EQ(a4[1].offset, capacity / 2);
       ASSERT_EQ(a4[1].length, 130 * _1m);
@@ -752,11 +752,11 @@ TEST(TestAllocatorLevel01, test_l2_contiguous_alignment)
       uint64_t allocated4 = 0;
       interval_vector_t a4;
       al2.allocate_l2(0x8000, 0x4000, &allocated4, &a4);
-      ASSERT_EQ(a4.size(), 2);
-      ASSERT_EQ(a4[0].offset, 0x8000);
-      ASSERT_EQ(a4[0].length, 0x4000);
+      ASSERT_EQ(a4.size(), 2u);
+      ASSERT_EQ(a4[0].offset, 0x8000u);
+      ASSERT_EQ(a4[0].length, 0x4000u);
       ASSERT_EQ(a4[1].offset, capacity / 2);
-      ASSERT_EQ(a4[1].length, 0x4000);
+      ASSERT_EQ(a4[1].length, 0x4000u);
     }
 
   }
index b022cfe9ecb05e762bfc7d6d443c0c08456c8ae6..284bd2fa88fb6d7349fc6c70663828c15a2b3d8e 100644 (file)
@@ -1448,14 +1448,14 @@ TEST(BlueStoreRepairer, StoreSpaceTracker)
   BlueStoreRepairer::StoreSpaceTracker bmap0;
   bmap0.init((uint64_t)4096 * 1024 * 1024 * 1024, 0x1000);
   ASSERT_EQ(bmap0.granularity, 2 * 1024 * 1024U);
-  ASSERT_EQ(bmap0.collections_bfs.size(), 2048 * 1024);
-  ASSERT_EQ(bmap0.objects_bfs.size(), 2048 * 1024);
+  ASSERT_EQ(bmap0.collections_bfs.size(), 2048u * 1024u);
+  ASSERT_EQ(bmap0.objects_bfs.size(), 2048u * 1024u);
 
   BlueStoreRepairer::StoreSpaceTracker bmap;
   bmap.init(0x2000 * 0x1000 - 1, 0x1000, 512 * 1024);
-  ASSERT_EQ(bmap.granularity, 0x1000);
-  ASSERT_EQ(bmap.collections_bfs.size(), 0x2000);
-  ASSERT_EQ(bmap.objects_bfs.size(), 0x2000);
+  ASSERT_EQ(bmap.granularity, 0x1000u);
+  ASSERT_EQ(bmap.collections_bfs.size(), 0x2000u);
+  ASSERT_EQ(bmap.objects_bfs.size(), 0x2000u);
 
   coll_t cid;
   ghobject_t hoid;
index 0da4f3ceef89e875ed676dd752861bad30d1275d..5bcb58cc0da1df3384e2fdef714efc86aed97e20 100644 (file)
@@ -125,7 +125,7 @@ TEST_F(MemStoreClone, CloneRangeHoleStart)
   t.write(cid, src, 8, 4, srcbl);
   t.write(cid, dst, 0, 12, dstbl);
   t.clone_range(cid, src, dst, 2, 8, 2);
-  ASSERT_EQ(0u, store->queue_transaction(ch, std::move(t)));
+  ASSERT_EQ(0, store->queue_transaction(ch, std::move(t)));
   ASSERT_EQ(12, store->read(ch, dst, 0, 12, result));
   ASSERT_EQ(expected, result);
 }
@@ -150,7 +150,7 @@ TEST_F(MemStoreClone, CloneRangeHoleMiddle)
   t.write(cid, src, 8, 4, srcbl);
   t.write(cid, dst, 0, 12, dstbl);
   t.clone_range(cid, src, dst, 2, 8, 2);
-  ASSERT_EQ(0u, store->queue_transaction(ch, std::move(t)));
+  ASSERT_EQ(0, store->queue_transaction(ch, std::move(t)));
   ASSERT_EQ(12, store->read(ch, dst, 0, 12, result));
   ASSERT_EQ(expected, result);
 }
@@ -175,7 +175,7 @@ TEST_F(MemStoreClone, CloneRangeHoleEnd)
   t.write(cid, src, 12, 4, srcbl);
   t.write(cid, dst, 0, 12, dstbl);
   t.clone_range(cid, src, dst, 2, 8, 2);
-  ASSERT_EQ(0u, store->queue_transaction(ch, std::move(t)));
+  ASSERT_EQ(0, store->queue_transaction(ch, std::move(t)));
   ASSERT_EQ(12, store->read(ch, dst, 0, 12, result));
   ASSERT_EQ(expected, result);
 }
index 1a476545394a8e370b7893f92b7ccd7eb571eb66..ac7067d3c00f1bab4b828e3a66016f87a98dda58 100644 (file)
@@ -698,7 +698,7 @@ TEST(pick_address, filtering)
                           &one, &av);
     cout << av << std::endl;
     ASSERT_EQ(0, r);
-    ASSERT_EQ(1, av.v.size());
+    ASSERT_EQ(1u, av.v.size());
     ASSERT_EQ(string("[::]:0/0"), stringify(av.v[0]));
   }
   {
@@ -724,7 +724,7 @@ TEST(pick_address, filtering)
                           &one, &av);
     cout << av << std::endl;
     ASSERT_EQ(0, r);
-    ASSERT_EQ(1, av.v.size());
+    ASSERT_EQ(1u, av.v.size());
     ASSERT_EQ(string("10.2.1.123:0/0"), stringify(av.v[0]));
     cct->_conf.set_val("public_network", "");
     cct->_conf.set_val("public_network_interface", "");
@@ -739,7 +739,7 @@ TEST(pick_address, filtering)
                           &one, &av);
     cout << av << std::endl;
     ASSERT_EQ(0, r);
-    ASSERT_EQ(1, av.v.size());
+    ASSERT_EQ(1u, av.v.size());
     ASSERT_EQ(string("10.2.1.123:0/0"), stringify(av.v[0]));
     cct->_conf.set_val("public_network", "");
     cct->_conf.set_val("cluster_network", "");
@@ -754,7 +754,7 @@ TEST(pick_address, filtering)
                           &one, &av);
     cout << av << std::endl;
     ASSERT_EQ(0, r);
-    ASSERT_EQ(1, av.v.size());
+    ASSERT_EQ(1u, av.v.size());
     ASSERT_EQ(string("10.1.1.2:0/0"), stringify(av.v[0]));
     cct->_conf.set_val("public_network", "");
     cct->_conf.set_val("cluster_network", "");
@@ -769,7 +769,7 @@ TEST(pick_address, filtering)
                           &one, &av);
     cout << av << std::endl;
     ASSERT_EQ(0, r);
-    ASSERT_EQ(1, av.v.size());
+    ASSERT_EQ(1u, av.v.size());
     ASSERT_EQ(string("[2001:1234:5678:90ab::cdef]:0/0"), stringify(av.v[0]));
     cct->_conf.set_val("public_network", "");
   }
@@ -784,7 +784,7 @@ TEST(pick_address, filtering)
                           &one, &av);
     cout << av << std::endl;
     ASSERT_EQ(0, r);
-    ASSERT_EQ(2, av.v.size());
+    ASSERT_EQ(2u, av.v.size());
     ASSERT_EQ(string("[2001:1234:5678:90ab::cdef]:0/0"), stringify(av.v[0]));
     ASSERT_EQ(string("10.2.1.123:0/0"), stringify(av.v[1]));
     cct->_conf.set_val("public_network", "");
@@ -802,7 +802,7 @@ TEST(pick_address, filtering)
                           &one, &av);
     cout << av << std::endl;
     ASSERT_EQ(0, r);
-    ASSERT_EQ(2, av.v.size());
+    ASSERT_EQ(2u, av.v.size());
     ASSERT_EQ(string("10.2.1.123:0/0"), stringify(av.v[0]));
     ASSERT_EQ(string("[2001:1234:5678:90ab::cdef]:0/0"), stringify(av.v[1]));
     cct->_conf.set_val("public_network", "");
@@ -819,7 +819,7 @@ TEST(pick_address, filtering)
                           &one, &av);
     cout << av << std::endl;
     ASSERT_EQ(0, r);
-    ASSERT_EQ(2, av.v.size());
+    ASSERT_EQ(2u, av.v.size());
     ASSERT_EQ(string("msgr2:[2001:1234:5678:90ab::cdef]:0/0"), stringify(av.v[0]));
     ASSERT_EQ(string("[2001:1234:5678:90ab::cdef]:0/0"), stringify(av.v[1]));
     cct->_conf.set_val("public_network", "");
@@ -834,7 +834,7 @@ TEST(pick_address, filtering)
                           &one, &av);
     cout << av << std::endl;
     ASSERT_EQ(0, r);
-    ASSERT_EQ(2, av.v.size());
+    ASSERT_EQ(2u, av.v.size());
     ASSERT_EQ(string("msgr2:0.0.0.0:0/0"), stringify(av.v[0]));
     ASSERT_EQ(string("0.0.0.0:0/0"), stringify(av.v[1]));
   }