Merged
Conversation
9c3c981 to
619bfee
Compare
Mixing the types uint64_t and `unsigned long long` does not compile on platforms that map uint64_t to `unsigned long long` instead of `unsigned long`. In addition, this commit uses the largest type between (a) and (b) instead of only the type of (a).
f3write was the only user of parameter func_flush_chunk of init_flow().
Making dbuf_get_buf() alignment aware simplifies the code since callers no longer need to deal with alignment.
Field total_processed can be derived from fields measured_blocks, processed_blocks, and block_size.
There's no need to mix signed and unsigned fields in struct flow.
Most of the code in the commit is to refactor the code for the change of unit from bytes to blocks.
This commit also changes the parameter processed of measure() to processed_blocks.
8a17b56 to
6f0240f
Compare
5631495 to
f465796
Compare
f465796 to
2678af6
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Since spinning off
f3writein 2020,libflowhas become a key aspect of how F3 works and is currently employed inf3write,f3read,f3brew, andf3probe. This pull request streamlines the interface oflibflowby<<), right shift (>>), and AND (&).In addition, this interface review brings the following minor improvements:
total_size→total_blocks,step→step_blocks, andget_rem_chunk_size()→get_rem_chunk_blocks()).func_flush_chunkparameter frominit_flow()and the redundanttotal_processedfield fromstruct flow.start_measurement().dbuf_get_buf()alignment-aware, so several callers dropped their ad hoc solutions for memory alignment.