Skip to content

Conversation

RobertPieta
Copy link

Remove expensive map and exit earlier. Should achieve performance improvement, significantly in cases where the indexSet has many intervals.

@spevans
Copy link
Contributor

spevans commented Jun 15, 2018

@swift-ci please test

@RobertPieta RobertPieta force-pushed the nsindexset_isequal_performance_enhancement branch from b4e0c6f to 01fa634 Compare June 15, 2018 23:43
@alblue
Copy link
Contributor

alblue commented Jun 26, 2018

A further optimisation would be to store the indexSet.rangeView into a constant at the start, and then use that in both places it is used in the function.

@millenomi
Copy link
Contributor

@swift-ci please test and merge

@swift-ci swift-ci merged commit 7df89db into swiftlang:master Oct 10, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants