Skip to content
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

Fix performance regressions for heuristics #4490

Closed
jleibs opened this issue Dec 12, 2023 · 0 comments · Fixed by #4563
Closed

Fix performance regressions for heuristics #4490

jleibs opened this issue Dec 12, 2023 · 0 comments · Fixed by #4563
Assignees
Labels
🟦 blueprint The data that defines our UI 📉 performance Optimization, memory use, etc
Milestone

Comments

@jleibs
Copy link
Member

jleibs commented Dec 12, 2023

We run a query for every candidate space view during creation. This is extremely painful when we have a bunch of image spaces, for example. Need to be much smarter about how we evaluate candidates.

@jleibs jleibs added 📉 performance Optimization, memory use, etc 🟦 blueprint The data that defines our UI labels Dec 12, 2023
@jleibs jleibs added this to the 0.12 milestone Dec 12, 2023
@Wumpf Wumpf self-assigned this Dec 14, 2023
Wumpf added a commit that referenced this issue Dec 15, 2023
…isolating per space view class (#4540)

### What

* Refactor towards #4490

This will allow us to store additional state with each registry entry:
This will be used to register a `VisualizerEntitySubscriber` and store a
handle to it for every visualizer.

All the "interesting" changes are in
`crates/re_viewer_context/src/space_view/space_view_class_registry.rs`,
everything else is just ripples.

Note that this pr sneakily starts the renaming of `ViewPart(System)` to
just `Visualizer`

### Checklist
* [x] I have read and agree to [Contributor
Guide](https://github.com/rerun-io/rerun/blob/main/CONTRIBUTING.md) and
the [Code of
Conduct](https://github.com/rerun-io/rerun/blob/main/CODE_OF_CONDUCT.md)
* [x] I've included a screenshot or gif (if applicable)
* [x] I have tested the web demo (if applicable):
  * Full build: [app.rerun.io](https://app.rerun.io/pr/4540/index.html)
* Partial build:
[app.rerun.io](https://app.rerun.io/pr/4540/index.html?manifest_url=https://app.rerun.io/version/nightly/examples_manifest.json)
- Useful for quick testing when changes do not affect examples in any
way
* [x] The PR title and labels are set such as to maximize their
usefulness for the next release's CHANGELOG

- [PR Build Summary](https://build.rerun.io/pr/4540)
- [Docs
preview](https://rerun.io/preview/13e2dbf32f0dd151e7ce18c2b98af9f1f929eb63/docs)
<!--DOCS-PREVIEW-->
- [Examples
preview](https://rerun.io/preview/13e2dbf32f0dd151e7ce18c2b98af9f1f929eb63/examples)
<!--EXAMPLES-PREVIEW-->
- [Recent benchmark results](https://build.rerun.io/graphs/crates.html)
- [Wasm size tracking](https://build.rerun.io/graphs/sizes.html)
@jleibs jleibs self-assigned this Dec 20, 2023
Wumpf pushed a commit that referenced this issue Dec 21, 2023
…te query and update_properties passes (#4563)

### What

- Resolves: #4490

After adding some scopes, found some more wins on query processing. This
is a mixture of some optimized short-circuit early-outs, and doing the
PropertyOverride logic on a second-pass in order to avoid any overhead
related to creating the EntityProperty structures and override
entity-paths.

This has the added benefit of also removing the second query and
replacing it with a much easier-to-follow override processor.

Before:

![image](https://github.com/rerun-io/rerun/assets/3312232/f7564835-575e-443a-8933-073471d4452f)

After:

![image](https://github.com/rerun-io/rerun/assets/3312232/f555515e-c8a2-491f-a00f-b8f67f79568e)

### Checklist
* [x] I have read and agree to [Contributor
Guide](https://github.com/rerun-io/rerun/blob/main/CONTRIBUTING.md) and
the [Code of
Conduct](https://github.com/rerun-io/rerun/blob/main/CODE_OF_CONDUCT.md)
* [x] I've included a screenshot or gif (if applicable)
* [x] I have tested the web demo (if applicable):
* Using newly built examples:
[app.rerun.io](https://app.rerun.io/pr/4563/index.html)
* Using examples from latest `main` build:
[app.rerun.io](https://app.rerun.io/pr/4563/index.html?manifest_url=https://app.rerun.io/version/main/examples_manifest.json)
* Using full set of examples from `nightly` build:
[app.rerun.io](https://app.rerun.io/pr/4563/index.html?manifest_url=https://app.rerun.io/version/nightly/examples_manifest.json)
* [x] The PR title and labels are set such as to maximize their
usefulness for the next release's CHANGELOG

- [PR Build Summary](https://build.rerun.io/pr/4563)
- [Docs
preview](https://rerun.io/preview/def055e32c466a530ea2c3761b42ae01440f6c20/docs)
<!--DOCS-PREVIEW-->
- [Examples
preview](https://rerun.io/preview/def055e32c466a530ea2c3761b42ae01440f6c20/examples)
<!--EXAMPLES-PREVIEW-->
- [Recent benchmark results](https://build.rerun.io/graphs/crates.html)
- [Wasm size tracking](https://build.rerun.io/graphs/sizes.html)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🟦 blueprint The data that defines our UI 📉 performance Optimization, memory use, etc
Projects
None yet
2 participants