os/bluestore: Recompression, part 1. Nice debugs.#54075
Conversation
|
This pull request has been automatically marked as stale because it has not had any activity for 60 days. It will be closed if no further activity occurs for another 30 days. |
src/os/bluestore/BlueStore.h
Outdated
| printer print(uint8_t mode) const { | ||
| return printer(*this, mode); | ||
| } |
There was a problem hiding this comment.
shouldn't the printer be a singleton? If we add to many prints it will instantiate a printer every time we print something.
|
unstale |
9cf8f02 to
837ed80
Compare
|
jenkins test make check |
|
jenkins test api |
| std::ostream &operator<<(std::ostream &out, const maybe_K &k) { | ||
| if (((k.x & 0x3ff) == 0) && (k.x != 0)) { | ||
| if (k.x != 0x400) | ||
| out << (k.x / 0x400); |
There was a problem hiding this comment.
x / 0x400 compiles to shl x, 10, but retains relation to above condition.
837ed80 to
1cebd19
Compare
| << ", " << o.extent_map.spanning_blob_map.size() | ||
| << " spanning blobs" << std::endl; | ||
| const BlueStore::ExtentMap& map = o.extent_map; | ||
| std::set<BlueStore::Blob*> visited; |
There was a problem hiding this comment.
do we want to create a set of length number_of_extents only to print? Feels like overkill and expensive. If it's marked as shared blob then it shouldn't be hard to parse why there are duplicates.
There was a problem hiding this comment.
Maybe we want to wrap this logic in a "mode", where you say: "okay I want finer grained information or high tailored one"
|
jenkins test make check |
|
jenkins test windows |
|
jenkins test api |
5a672c0 to
907faba
Compare
|
jenkins test api |
|
This pull request can no longer be automatically merged: a rebase is needed and changes have to be manually resolved |
907faba to
a0f4c4e
Compare
|
jenkins test api |
|
This pull request can no longer be automatically merged: a rebase is needed and changes have to be manually resolved |
a0f4c4e to
d6a1b09
Compare
|
This pull request can no longer be automatically merged: a rebase is needed and changes have to be manually resolved |
Introduce printer class that allows to select parts of Blob that are to be printed. It severly reduced amount of clutter in output. Usage: using P = Bluestore::Blob::printer; dout << blob->printer(P::ptr + P::sdisk + P::schk); Signed-off-by: Adam Kupczyk <akupczyk@ibm.com>
Modify Extent similar to Blob, so that one can use improved Blob printing when printing extents. Signed-off-by: Adam Kupczyk <akupczyk@ibm.com>
Now printing Blob can include buffers. There are 2 variants: - 'buf' same as original in dump_onode - 'sbuf' only fundamental params, no ptr etc. Signed-off-by: Adam Kupczyk <akupczyk@ibm.com>
Added nice replacement for dump_onode function. Introduce printer class that allows to select parts of Onode that are to be printed. It severly reduced amount of clutter in output. Usage: using P = Bluestore::printer; dout << blob->print(P::ptr + P::sdisk + P::schk + P::buf + P::attrs); Signed-off-by: Adam Kupczyk <akupczyk@ibm.com>
- moved operator<< to BlueStore_debug file
- upcased Printer {} flags
- more reliable heap begin detection
- fixup after rebase
Signed-off-by: Adam Kupczyk <akupczyk@ibm.com>
Small improvement on debug output. Signed-off-by: Adam Kupczyk <akupczyk@ibm.com>
From define in .cc to constexpr in .h Signed-off-by: Adam Kupczyk <akupczyk@ibm.com>
Now Onode can be printed in selected range. It is useful in high-level dout modes that operate on a fragment of entire Onode. Signed-off-by: Adam Kupczyk <akupczyk@ibm.com>
BufferSpace moved from Blob to Onode. Moved relevant code from Blob::operator<< to Onode::operator<<. Signed-off-by: Adam Kupczyk <akupczyk@ibm.com>
d6a1b09 to
f400cb1
Compare
|
jenkins test make check |
Introduce printer class that allows to select parts of Blob that are to be printed.
It severly reduced amount of clutter in output.
Usage:
using P = Bluestore::Blob::printer;
dout << blob->printer(P::nick + P::sdisk + P::schk);
Now the Blob printout can look like this:
Blob(rtrvlad disk=0x[12503~e,19589~1,12512~1]000 track=16*4K{4K}[] )instead of
Blob(0x55555e735790 blob([0x12503000~e000,0x19589000~1000,0x12512000~1000] llen=0x10000 csum crc32c/0x1000/64) use_tracker(0x10*0x1000 0x[1000,1000,1000,1000,1000,1000,1000,1000,1000,1000,1000,1000,1000,1000,1000,1000]) SharedBlob(0x55555e9e8680 sbid 0x0))#54075 Nice debugs.
#54504 New write path.
#57448 Segmented onode.
#56975 Main
#57450 Test
Contribution Guidelines
To sign and title your commits, please refer to Submitting Patches to Ceph.
If you are submitting a fix for a stable branch (e.g. "pacific"), please refer to Submitting Patches to Ceph - Backports for the proper workflow.
Checklist
Show available Jenkins commands
jenkins retest this pleasejenkins test classic perfjenkins test crimson perfjenkins test signedjenkins test make checkjenkins test make check arm64jenkins test submodulesjenkins test dashboardjenkins test dashboard cephadmjenkins test apijenkins test docsjenkins render docsjenkins test ceph-volume alljenkins test ceph-volume toxjenkins test windows