Open
Conversation
Signed-off-by: Ivan Santiago Paunovic <ivanpauno@ekumenlabs.com>
Signed-off-by: Ivan Santiago Paunovic <ivanpauno@ekumenlabs.com>
Signed-off-by: Ivan Santiago Paunovic <ivanpauno@ekumenlabs.com>
Signed-off-by: Ivan Santiago Paunovic <ivanpauno@ekumenlabs.com>
Signed-off-by: Ivan Santiago Paunovic <ivanpauno@ekumenlabs.com>
Collaborator
Author
I knew I was doing something wrong there when I saw the test failures, but I couldn't find the problem 😂. |
jacobperron
reviewed
Jan 26, 2022
jacobperron
left a comment
There was a problem hiding this comment.
LGTM, I'd like to test this out before we merge it.
Signed-off-by: Ivan Santiago Paunovic <ivanpauno@ekumenlabs.com> Co-authored-by: Jacob Perron <jacob@openrobotics.org>
This file contains hidden or 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
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 PR applies two minor improvements:
Doesn't reduce time complexity, but it reduces the total amount of "operations" done.
The second item seems to be a good improvement as allocation/deallocation is slow.
I have still some tests issues that I'm trying to figure out.Solved!I have done some profiling, though nothing great (I need to create a demo with more entities to get more interesting results)
To profile:
./visualvm_212/bin/visualvmafter extracting the archive.org.ros2.rcljava.examples.subscriber.SubscriberLambda (pid <pid>)entry inLocal.profilertab and addorg.ros2.rcljava.executors.**to the "profile classes:" list.I have compared between this branch and main:
It's reasonable because I'm only testing with one subscription available.
waitForWork() went from taking 50% of the time to 37%.
We still need to test in a more realistic application to confirm.
Note: To make the measurements stable, I have disabled frequently scaling in my machine temporally.
See for example here for details.