Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Movable io_blob_safe does not require wrapping. #59

Merged
merged 3 commits into from
Sep 16, 2023
Merged

Conversation

szmyd
Copy link
Collaborator

@szmyd szmyd commented Sep 15, 2023

No description provided.

@szmyd szmyd requested a review from xiaoxichen September 15, 2023 22:07
@codecov-commenter
Copy link

Codecov Report

Patch coverage: 100.00% and project coverage change: +0.25% 🎉

Comparison is base (57fe3e6) 81.78% compared to head (54f3da4) 82.04%.

❗ Your organization needs to install the Codecov GitHub app to enable full functionality.

Additional details and impacted files
@@            Coverage Diff             @@
##             main      #59      +/-   ##
==========================================
+ Coverage   81.78%   82.04%   +0.25%     
==========================================
  Files          16       16              
  Lines         247      245       -2     
  Branches       25       25              
==========================================
- Hits          202      201       -1     
+ Misses         29       28       -1     
  Partials       16       16              
Files Changed Coverage Δ
src/include/homeobject/blob_manager.hpp 50.00% <100.00%> (+50.00%) ⬆️
src/lib/blob_manager.cpp 83.33% <100.00%> (+3.33%) ⬆️
src/lib/memory/blob_manager.cpp 83.87% <100.00%> (-0.34%) ⬇️

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@szmyd szmyd changed the title Movable blob Movable io_blob_safe does not require wrapping. Sep 16, 2023
@@ -31,4 +31,10 @@ BlobManager::NullAsyncResult HomeObjectImpl::del(shard_id shard, blob_id const&
});
}

Blob Blob::clone() const {
auto new_body = sisl::io_blob_safe(body.size);
std::memcpy(new_body.bytes, body.bytes, body.size);
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can we add deep copy into the copy assignment of io_blob_safe?
are we on purpose delete that to avoid unconscious deep-copy?

Copy link
Collaborator Author

@szmyd szmyd Sep 16, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You mean move the memcpy down? Yeah; we can talk to hari about that; it'd be a sisl change; but still a clone() operation i think for the reason you point out.

@szmyd szmyd merged commit 951d61d into eBay:main Sep 16, 2023
24 checks passed
@szmyd szmyd deleted the movable_blob branch September 16, 2023 02:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants