Skip to content
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

Improve Merge operation performance #1183

merged 1 commit into from Apr 15, 2019


None yet
2 participants
Copy link

Pankraty commented Apr 15, 2019

As @b0bi79 has discovered, XLRangeBase.Merge() is not quite efficient: cellsUsed is enumerated multiple times.

In addition, LastCellUsed() method is called in CellRangeReference twice so this part was also improved.

In my testing example, the execution time changes from 17 sec to 11 sec (>130K random merges).


igitur approved these changes Apr 15, 2019

@igitur igitur added this to the v0.95 milestone Apr 15, 2019

@igitur igitur added the enhancement label Apr 15, 2019


This comment has been minimized.

Copy link

igitur commented Apr 15, 2019

Nice find.

@igitur igitur merged commit 3dcf107 into ClosedXML:develop Apr 15, 2019

1 check passed

continuous-integration/appveyor/pr AppVeyor build succeeded
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.