-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
ls: Lazily obtain FileType, eagerly obtain Metadata when Metadata is available #8753
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
Conversation
This reverts commit 34cbcb3.
|
GNU testsuite comparison: |
CodSpeed Performance ReportMerging #8753 will improve performances by 11.28%Comparing Summary
Benchmarks breakdown
Footnotes
|
|
GNU testsuite comparison: |
|
GNU testsuite comparison: |
|
GNU testsuite comparison: |
|
GNU testsuite comparison: |
| // it will avoid a call to stat() | ||
| if !self.must_dereference { | ||
| if let Some(dir_entry) = &self.de { | ||
| if let Some(dir_entry) = RefCell::take(&self.de).as_deref() { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
RefCell::take() permanently removes the value, no ?
(it might impact caching)
Did you consider using self.de.borrow() instead ?

Cleanup PathData, remove requirement for mutable state.
Would fix: #8350