Refactor MappingInfo class to use XML stream parser instead of full XmlParse#15636
Merged
Conversation
daschuer
requested changes
Nov 20, 2025
Member
daschuer
left a comment
There was a problem hiding this comment.
Thank you for this PR. I have suggested some improvements.
Swiftb0y
approved these changes
Nov 20, 2025
Member
Swiftb0y
left a comment
There was a problem hiding this comment.
I agree with all the changes proposed by Daniel. LGTM to me apart from those.
f0fc784 to
22837f9
Compare
performance and consistency in string comparisons and attribute lookups. Switched from `QString` to `QStringView` for lightweight, non-owning string handling in `xmlElementName` and `protocol` variables, reducing memory allocations.
Swiftb0y
reviewed
Nov 22, 2025
daschuer
approved these changes
Nov 23, 2025
Member
daschuer
left a comment
There was a problem hiding this comment.
LGTM. Thank you.
Is this ready for merge now?
Member
Author
|
Yes! |
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.
Mixxx parses all XML controller mappings at every startup, but only the tiny info section is needed here.
This PR replace the parsing of the full XML file, by stream reading which is stopped once the info section is read. The info section is usually at the beginning of an XML mapping file.
On my system this PR saves ~200ms startup time.