Cache walk_packages in ad-hoc framework at collection time#4577
Cache walk_packages in ad-hoc framework at collection time#4577jtraglia merged 6 commits intoethereum:masterfrom
Conversation
It saves 5 secs in mine, but I guess mine is slower, it is a M1 macbook. And also it depends on the load of other apps. Unless we don't run a server with a very specific config always that only runs this it is very difficult to make a very scientific assetment. If you argue that the performance gain is not worth it, we can close this. |
|
|
@jtraglia I fixed the bug, I was storing the interator instead of the list. I have now |
Hmm this is still a different count (more now). What new tests is this finding? In my screenshot:
|
My desktop is an M1 Mac mini, so it's practically the same as your MacBook btw. So I'm not sure why yours is noticeably slower. And you don't have to do
Performance wise, probably not worth it. But if it's finding missing test cases, definitely worth merging. |
|
I am going to get the arrays of the collected tests in both versions and check why is the difference |
|
@jtraglia I am getting 193198 total in both master and here, after merging master. I think the reason for the divergence was different versions from master and the commit this was based on. |
Ah I see. Okay thanks for double checking that. Makes sense.
I think I'd like to make this argument. The extra complexity is not worth the small performance improvement. |
|
@leolara these don't match for me. Using the latest commit here after I pulling changes from master.
|
|
I check again |
95279dd to
c4b57b4
Compare
|
@jtraglia check the code, I have added an assertion that checks they must be the same |
Have you compared to master like I did? |
|
But yes, I see your new assertion. I will look into it. |
|
Yes I a different when running |
|
These are the test cases that are different: |
|
It is weird, the last commit doesn't show in the diff of the PR. That might be the cause. |
|
I am getting the same exact tests now. |
99ac28f to
a3b22d0
Compare
jtraglia
left a comment
There was a problem hiding this comment.
LGTM. Can confirm they are the same now.





This improve greatly the collection time with some tests done in my laptop.
Also, clarifies the names of some variables where "module" and "package" were being used incorrectly.