-
-
Notifications
You must be signed in to change notification settings - Fork 3.1k
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
Optimize kv binding2 #2533
Merged
Merged
Optimize kv binding2 #2533
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
…e the _bind_with_args to fast_bind. Add docs.
…fines the binding methods.
…exception for non-existant prop.
…hing in EventDispatcher Property.
…fault value of getattr is not broken.
Closed
EXCELLENT! |
Did you fixed the issue that @tshirtman got on the old branch? #2368 (comment) |
i think d6a4367 fixes it. and yeah 👍 on the awesome work :) |
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.
This is a rebase of #2368.
In the last commit, I replaced the binding methods to use a optimized linked list for storing the callbacks instead of the list. The reason is that, although binding and creation of complex widgets seemed faster with this branch, in the kivy.tools.benchmark, my branch was worse than master. After tinkering, the reason is that my branch add a slight cost for storing the largs. The cost of storing the largs < cost of partial, so for complex widgets that made use a lot of partial in lang.py my branch was fatser. But for simpler widgets, the added small cost of saving the largs dominated, hence the benchmark.
benchmark results:
https://gist.github.com/matham/f0becba89f249bc1455b shows the kivy.tools.benchmark.outcome as measured on my system.
The timeit benchmarks from the original pr is still pretty much the same. here's the retested values: