Optimize data cluster format for VHD and QCOW#6895
Draft
last-genius wants to merge 6 commits intoxapi-project:26.1-lcmfrom
Draft
Optimize data cluster format for VHD and QCOW#6895last-genius wants to merge 6 commits intoxapi-project:26.1-lcmfrom
last-genius wants to merge 6 commits intoxapi-project:26.1-lcmfrom
Conversation
…rmat Qcow_stream now uses Qcow_mapping to store information on allocated clusters, which offers .to_interval_seq, outputting a list of pairs representing intervals of allocated virtual clusters. Signed-off-by: Andrii Sultanov <andriy.sultanov@vates.tech>
Now that qcow-stream-tool output intervals of allocated clusters, do the same for vhd-tool. This greatly decreases the filesize and memory usage in vhd-tool. Signed-off-by: Andrii Sultanov <andriy.sultanov@vates.tech>
This requires switching stream_vdi to the new format, away from the memory-costly Map storing information on every single allocated cluster. Signed-off-by: Andrii Sultanov <andriy.sultanov@vates.tech>
…er allocation Instead of using a set with every individual allocated cluster index as a member, use a sorted list of intervals to verify if cluster is allocated - this uses much less memory and directly follows from the JSON format qcow-stream-tool and vhd-tool output now. Signed-off-by: Andrii Sultanov <andriy.sultanov@vates.tech>
…_clusters nonzero_clusters no longer contain every single allocated cluster and instead are intervals of allocated clusters. Signed-off-by: Andrii Sultanov <andriy.sultanov@vates.tech>
… files Signed-off-by: Andrii Sultanov <andriy.sultanov@vates.tech>
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.
mirage/ocaml-qcow#134 changes the type of the data structure containing info on allocated data clusters, returning allocated intervals instead of all the virtual cluster addresses. Modify
vhd-toolas well to conform to this format, and change the parsing code invhd_qcow_parsingandqcow2-to-stdout.I've ran vm export and vdi integrity quicktests and tested this extensively locally. The PR will only build once the new ocaml-qcow version is packaged into xs-opam, so keeping this as draft for now.