Skip to content

Conversation

Myriad-Dreamin
Copy link
Owner

@Myriad-Dreamin Myriad-Dreamin commented Oct 11, 2024

Intel vtune says dirs::data_dir and dirs::cache_dir make syscall on windows for each check existence of package files. This is a disaster on large packages.

With caching, the time used of tinymist query packageDocs --id @preview/cetz:0.2.2 goes down from 0.9s to 0.7s.

Intel vtune also says sys::stat syscall takes 0.2s to check existence of package files, but this need more careful cache strategy.

Though we currently don't response changes of these two cached directory paths, it is less likely to be changed in application wide.

@Myriad-Dreamin Myriad-Dreamin merged commit 69aef36 into main Oct 11, 2024
15 checks passed
@Myriad-Dreamin Myriad-Dreamin deleted the cache-package-dirs branch October 12, 2024 01:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant