-
-
Notifications
You must be signed in to change notification settings - Fork 70
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Drastically Improve Speed and Memory Performance #253
Merged
Merged
Conversation
This file contains 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
cpisciotta
force-pushed
the
charles/memory-improvements
branch
from
February 25, 2024 17:59
d0f9320
to
cbc94b2
Compare
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #253 +/- ##
==========================================
- Coverage 85.76% 84.94% -0.82%
==========================================
Files 14 14
Lines 1545 1461 -84
==========================================
- Hits 1325 1241 -84
Misses 220 220 ☔ View full report in Codecov by Sentry. |
Closed
This was
linked to
issues
Feb 25, 2024
Closed
cpisciotta
added a commit
that referenced
this pull request
Feb 25, 2024
- Consolidate `captureGroups` logic into `Regex` - Constrain `pattern` - Drastically reduce instantiations of `NSRegularExpression` - Exit early on empty lines - Mark `Regex` as `final` - Add `large_xcodebuild_log` test to (1) identify the bottleneck and (2) prevent a future bottleneck - Add time tracking to `run` - Move `CaptureGroup.Type` array into static property See testing results [here](#253).
cpisciotta
added a commit
that referenced
this pull request
Feb 25, 2024
## Changes Drastically improve xcbeautify's performance (time and memory). Testing with a large xcodebuild log, this change dropped xcbeautify's execution time by ~90% and memory footprint by ~99%. - Reduce unnecessary type instantiations, namely NSRegularExpression. - Skip parsing empty lines. - Introduce time-tracking logic and large xcodebuild log test to (1) find and fix the existing issue and (2) prevent future performance regressions. ## Testing See testing results [here](#253).
cpisciotta
added a commit
that referenced
this pull request
Feb 25, 2024
Drastically improve xcbeautify's performance (time and memory). Testing with a large xcodebuild log, this change dropped xcbeautify's execution time by ~90% and memory footprint by ~99%. - Reduce unnecessary type instantiations, namely NSRegularExpression. - Skip parsing empty lines. - Introduce time-tracking logic and large xcodebuild log test to (1) find and fix the existing issue and (2) prevent future performance regressions. See testing results [here](#253).
cpisciotta
added a commit
that referenced
this pull request
Feb 25, 2024
Drastically improve xcbeautify's performance (time and memory). Testing with a large xcodebuild log, this change dropped xcbeautify's execution time by ~90% and memory footprint by ~99%. - Reduce unnecessary type instantiations, namely NSRegularExpression. - Skip parsing empty lines. - Introduce time-tracking logic and large xcodebuild log test to (1) find and fix the existing issue and (2) prevent future performance regressions. See testing results [here](#253).
cpisciotta
added a commit
that referenced
this pull request
Feb 25, 2024
Drastically improve xcbeautify's performance (time and memory). Testing with a large xcodebuild log, this change dropped xcbeautify's execution time by ~90% and memory footprint by ~99%. - Reduce unnecessary type instantiations, namely NSRegularExpression. - Skip parsing empty lines. - Introduce time-tracking logic and large xcodebuild log test to (1) find and fix the existing issue and (2) prevent future performance regressions. See testing results [here](#253).
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.
Changes
Drastically improve xcbeautify's performance (time and memory). Testing with a large xcodebuild log, this change dropped xcbeautify's execution time by ~90% and memory footprint by ~99%.
NSRegularExpression
.Testing
Average results after formatting large_xcodebuild_log.txt (99.9 MB xcodebuild log).