Skip to content

Conversation

leebyron
Copy link
Contributor

This converts the O(N^2) cycle detector to an O(N) detector and optimizes the visit to short-circuit where parts of the validation visitor were unnecessary.

On an internal very large stress test query this was previously ~30s and after this diff runs in 15ms.

This converts the O(N^2) cycle detector to an O(N) detector and optimizes the visit to short-circuit where parts of the validation visitor were unnecessary.

On an internal very large stress test query this was previously ~30s and after this diff runs in 15ms.
@leebyron
Copy link
Contributor Author

In addition, also finds more cycle cases the previous algorithm did not. Win!

leebyron added a commit that referenced this pull request Nov 13, 2015
[Validation] perf improvements for fragment cycle detection
@leebyron leebyron merged commit 7278b7c into master Nov 13, 2015
@leebyron leebyron deleted the fast-cycle-detection branch November 13, 2015 07:55
@KyleAMathews
Copy link

👏🏻
On Thu, Nov 12, 2015 at 11:55 PM Lee Byron [email protected] wrote:

Merged #231 #231.


Reply to this email directly or view it on GitHub
#231 (comment).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants