]> git.apps.os.sepia.ceph.com Git - ceph.git/commit
crimson/os: use reference for loop variable 41885/head
authorKefu Chai <kchai@redhat.com>
Wed, 16 Jun 2021 11:58:42 +0000 (19:58 +0800)
committerKefu Chai <kchai@redhat.com>
Wed, 16 Jun 2021 11:58:50 +0000 (19:58 +0800)
commit84c71bc22fba344eb47db72ed9e29f11163c2638
tree4075930f0105695ad62b7aaa2a55513feeac0d09
parent11216507aa75ce9f7a94840c5550c97518ae1279
crimson/os: use reference for loop variable

for better performance, also silences the warning like:

../src/crimson/os/seastore/random_block_manager/nvme_manager.cc:444:23: warning: loop variable ‘b’ creates a copy from type ‘const crimson::os::seastore::rbm_alloc_delta_t’ [-Wrange-loop-construct]
  444 |       for (const auto b : alloc_blocks) {
      |                       ^

Signed-off-by: Kefu Chai <kchai@redhat.com>
src/crimson/os/seastore/random_block_manager/nvme_manager.cc