Skip to content

Docs' index seems broken and crashes web tabs #3555

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

Closed
eugenesvk opened this issue Mar 21, 2025 · 4 comments
Closed

Docs' index seems broken and crashes web tabs #3555

eugenesvk opened this issue Mar 21, 2025 · 4 comments
Labels
question Further information is requested

Comments

@eugenesvk
Copy link

eugenesvk commented Mar 21, 2025

Suggestion

When trying to use the docs for the crates at https://microsoft.github.io/windows-docs-rs/doc/windows/index.html I get a huge spike in memory use which some browsers can't (or choose not to) handle on Windows

  • In Chrome I get an out-of-memory crash for a tab after it reaches ~2.5G of memory use (total browser use, not for 1 tab, though only 1 tab is opened), though the system isn't OOM.
  • In Firefox the page continues to grow in memory use until ~4G (same, total browser use), then stabilizes.

I think simply focusing the search box triggers this huge growth, no need to even input any search string. Does it generate the full search index locally in a very inefficient way or something?

May I suggest improving the efficiency of the docs page?

@eugenesvk eugenesvk added the enhancement New feature or request label Mar 21, 2025
@kennykerr
Copy link
Collaborator

This is generated by rustdoc which is known to struggle with large crates, but is otherwise out of our control.

I'd suggest using https://microsoft.github.io/windows-rs/features/ to figure out which windows crate features you might need to enable but otherwise avoid the docs.

Alternatively, you can use the windows-bindgen crate to generate just the bindings you need.

@kennykerr kennykerr added question Further information is requested and removed enhancement New feature or request labels Mar 21, 2025
@riverar
Copy link
Collaborator

riverar commented Mar 21, 2025

Are you clicking All Items in the docs? If so, don't do that. 😄

@eugenesvk
Copy link
Author

No clicking, though that's actually a non-issue, that page loads fine with lower memory use, and it might be lazy-loaded(?) when you jump to the end, it loads more (but still, jumping all the way to the last item doesn't crash anything)

@kennykerr
Copy link
Collaborator

kennykerr commented Mar 21, 2025

I think this is the main issue but there are probably others: rust-lang/rust#131156

See also #3509

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

3 participants