Bump default inline_max up to 1/4 block size #1146
Open
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.
As noted by @amgross, the current
inline_maxdefault (when littlefs switches from inline files to CTZ skip-lists) does not match the theoretical value in DESIGN.md.The reason for this is 1/8 was chosen as a safer default during development, due to concerns that 1/4 + mdirs splitting at 1/2 would lead to poor distribution of large inline files in mdirs.
However, two things have happened since then:
Experiments have show "wasted" mdir space is less of a concern than initially thought. Extra mdir space contributes to logging, delays mdir compaction, and can overall lead to better performance.
inline_sizewas added as a configuration option (#914), so if 1/4 is problematic users can always override it.So bumping this back up to 1/4 may make sense. Though open to feedback if this is worthwhile in the shadow of littlefs3.
Related: #1145
Note this is actually already bumped to 1/4 in littlefs3 (#1111, unstable).