Skip to content

Scene perf 2 #4246

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

Open
wants to merge 4 commits into
base: latest
Choose a base branch
from
Open

Scene perf 2 #4246

wants to merge 4 commits into from

Conversation

jacobp100
Copy link
Contributor

No description provided.

@jacobp100 jacobp100 requested review from alantreadway and a team as code owners May 21, 2025 15:50
@jacobp100
Copy link
Contributor Author

/benchmarks

Copy link
Contributor

github-actions bot commented May 21, 2025

1 similar comment
Copy link
Contributor

github-actions bot commented May 21, 2025

@jacobp100
Copy link
Contributor Author

/benchmarks

Copy link
Contributor

github-actions bot commented May 21, 2025

@jacobp100
Copy link
Contributor Author

/benchmarks

Copy link
Contributor

github-actions bot commented May 21, 2025

@jacobp100
Copy link
Contributor Author

/benchmarks

Copy link
Contributor

github-actions bot commented May 22, 2025

https://github.com/ag-grid/ag-charts/actions/runs/15181693901

Comparing latest-fd4e3476b70491216e782190fe68c8329591ddff (baseline) vs. scene-perf-2-ea1918001982cbb362d886081743c944d1c8c614
Time
┌─────────┬───────────────────────────────────────────┬───────────────┬──────────┬─────────┐
│ (index) │ test                                      │ pctTimeChange │ beforeMs │ afterMs │
├─────────┼───────────────────────────────────────────┼───────────────┼──────────┼─────────┤
│ 0       │ 'large-dataset (load 4x datum highlight)' │ -38.2         │ 2022     │ 1249    │
│ 1       │ 'large-dataset (load 1x datum highlight)' │ -35.6         │ 1086     │ 699     │
│ 2       │ 'sparkline initial load'                  │ -3.8          │ 9.9      │ 9.5     │
│ 3       │ 'simple-chart (load 10x legend toggle)'   │ -3.5          │ 144      │ 139     │
│ 4       │ 'simple-chart initial load'               │ -2.9          │ 58       │ 56      │
│ 5       │                                           │               │          │         │
│ 6       │ 'large-scale multi-series initial load'   │ 0.4           │ 1422     │ 1428    │
│ 7       │ 'multi-series (load 15x datum highlight)' │ 0.9           │ 882      │ 890     │
│ 8       │ 'multi-series initial load'               │ 1             │ 457      │ 462     │
│ 9       │ 'large-dataset initial load'              │ 1.7           │ 9087     │ 9245    │
│ 10      │ 'resize (load 10x resize)'                │ 6             │ 108      │ 114     │
└─────────┴───────────────────────────────────────────┴───────────────┴──────────┴─────────┘
Memory
┌─────────┬────────────────────────────────────────────────────┬─────────────────┬──────────┬─────────┐
│ (index) │ test                                               │ pctMemoryChange │ beforeMB │ afterMB │
├─────────┼────────────────────────────────────────────────────┼─────────────────┼──────────┼─────────┤
│ 0       │ 'large-dataset (load 1x datum highlight)'          │ -0.3            │ 982      │ 979     │
│ 1       │ 'large-scale multi-series initial load'            │ -0.3            │ 274      │ 273     │
│ 2       │ 'large-scale multi-series (load 1x legend toggle)' │ -0.3            │ 277      │ 277     │
│ 3       │ 'large-scale multi-series (load 4x legend toggle)' │ -0.3            │ 279      │ 278     │
│ 4       │ 'integrated charts large scale initial load'       │ -0.2            │ 243      │ 242     │
│ 5       │                                                    │                 │          │         │
│ 6       │ 'sparkline initial load (pooled)'                  │ -0              │ 167      │ 167     │
│ 7       │ 'sparkline (load update)'                          │ -0              │ 167      │ 167     │
│ 8       │ 'sparkline (load updateDelta)'                     │ -0              │ 167      │ 167     │
│ 9       │ 'zoom-large-dataset initial load'                  │ -0              │ 373      │ 373     │
│ 10      │ 'zoom-large-dataset (load 100x zoom)'              │ -0              │ 362      │ 361     │
└─────────┴────────────────────────────────────────────────────┴─────────────────┴──────────┴─────────┘

@jacobp100
Copy link
Contributor Author

/benchmarks

@jacobp100
Copy link
Contributor Author

/benchmarks

Copy link
Contributor

github-actions bot commented May 22, 2025

https://github.com/ag-grid/ag-charts/actions/runs/15183596151

Comparing latest-4791a14bd622270fbe89bf791c39d2fc0fe2ef35 (baseline) vs. scene-perf-2-866632f3e55434a350e7fd91383e933252b1daf1
Time
┌─────────┬─────────────────────────────────────────────────────────┬───────────────┬──────────┬─────────┐
│ (index) │ test                                                    │ pctTimeChange │ beforeMs │ afterMs │
├─────────┼─────────────────────────────────────────────────────────┼───────────────┼──────────┼─────────┤
│ 0       │ 'simple-chart (load 1x legend toggle)'                  │ -4.8          │ 33       │ 31      │
│ 1       │ 'large-dataset (load 4x datum highlight)'               │ -3.5          │ 1276     │ 1232    │
│ 2       │ 'sparkline initial load'                                │ -2.6          │ 9.8      │ 9.6     │
│ 3       │ 'sparkline initial load (pooled)'                       │ -2.6          │ 1.6      │ 1.6     │
│ 4       │ 'integrated charts large scale (load 1x legend toggle)' │ -2.3          │ 577      │ 564     │
│ 5       │                                                         │               │          │         │
│ 6       │ 'large-scale multi-series (load 1x legend toggle)'      │ 0.3           │ 1498     │ 1503    │
│ 7       │ 'multi-series (load 1x legend toggle)'                  │ 0.5           │ 259      │ 260     │
│ 8       │ 'large-dataset (load 1x datum highlight)'               │ 0.7           │ 724      │ 729     │
│ 9       │ 'large-scale multi-series (load 4x legend toggle)'      │ 0.8           │ 2849     │ 2870    │
│ 10      │ 'sparkline (load update)'                               │ 2.2           │ 1.2      │ 1.2     │
└─────────┴─────────────────────────────────────────────────────────┴───────────────┴──────────┴─────────┘
Memory
┌─────────┬─────────────────────────────────────────────────────────┬─────────────────┬──────────┬─────────┐
│ (index) │ test                                                    │ pctMemoryChange │ beforeMB │ afterMB │
├─────────┼─────────────────────────────────────────────────────────┼─────────────────┼──────────┼─────────┤
│ 0       │ 'large-scale multi-series initial load'                 │ -0.2            │ 273      │ 273     │
│ 1       │ 'large-scale multi-series (load 1x legend toggle)'      │ -0.2            │ 277      │ 277     │
│ 2       │ 'large-scale multi-series (load 4x legend toggle)'      │ -0.2            │ 279      │ 278     │
│ 3       │ 'integrated charts large scale initial load'            │ -0.1            │ 242      │ 242     │
│ 4       │ 'integrated charts large scale (load 1x legend toggle)' │ -0.1            │ 244      │ 244     │
│ 5       │                                                         │                 │          │         │
│ 6       │ 'zoom-large-dataset (load 100x zoom)'                   │ 0               │ 361      │ 361     │
│ 7       │ 'large-dataset initial load'                            │ 0.1             │ 921      │ 922     │
│ 8       │ 'large-dataset (load 1x legend toggle)'                 │ 0.1             │ 1090     │ 1091    │
│ 9       │ 'large-dataset (load 1x datum highlight)'               │ 0.1             │ 978      │ 979     │
│ 10      │ 'large-dataset (load 4x datum highlight)'               │ 0.1             │ 986      │ 987     │
└─────────┴─────────────────────────────────────────────────────────┴─────────────────┴──────────┴─────────┘

Copy link
Contributor

github-actions bot commented May 22, 2025

https://github.com/ag-grid/ag-charts/actions/runs/15183610907

Comparing latest-4791a14bd622270fbe89bf791c39d2fc0fe2ef35 (baseline) vs. scene-perf-2-866632f3e55434a350e7fd91383e933252b1daf1
Time
┌─────────┬─────────────────────────────────────────────────────────┬───────────────┬──────────┬─────────┐
│ (index) │ test                                                    │ pctTimeChange │ beforeMs │ afterMs │
├─────────┼─────────────────────────────────────────────────────────┼───────────────┼──────────┼─────────┤
│ 0       │ 'sparkline (load update)'                               │ -3.1          │ 1.2      │ 1.1     │
│ 1       │ 'sparkline initial load'                                │ -2.4          │ 9.8      │ 9.5     │
│ 2       │ 'simple-chart initial load'                             │ -1.4          │ 57       │ 56      │
│ 3       │ 'simple-chart (load 1x legend toggle)'                  │ -1.2          │ 32       │ 32      │
│ 4       │ 'simple-chart (load 10x legend toggle)'                 │ -1.2          │ 141      │ 140     │
│ 5       │                                                         │               │          │         │
│ 6       │ 'multi-series (load 1x legend toggle)'                  │ 0.8           │ 259      │ 262     │
│ 7       │ 'large-dataset (load 1x datum highlight)'               │ 1.2           │ 726      │ 735     │
│ 8       │ 'multi-series (load 1x datum highlight)'                │ 1.3           │ 99       │ 100     │
│ 9       │ 'large-dataset (load 4x datum highlight)'               │ 1.5           │ 1261     │ 1280    │
│ 10      │ 'integrated charts large scale (load 1x legend toggle)' │ 2.4           │ 567      │ 580     │
└─────────┴─────────────────────────────────────────────────────────┴───────────────┴──────────┴─────────┘
Memory
┌─────────┬─────────────────────────────────────────────────────────┬─────────────────┬──────────┬─────────┐
│ (index) │ test                                                    │ pctMemoryChange │ beforeMB │ afterMB │
├─────────┼─────────────────────────────────────────────────────────┼─────────────────┼──────────┼─────────┤
│ 0       │ 'large-scale multi-series initial load'                 │ -0.2            │ 273      │ 273     │
│ 1       │ 'large-scale multi-series (load 1x legend toggle)'      │ -0.2            │ 277      │ 277     │
│ 2       │ 'large-scale multi-series (load 4x legend toggle)'      │ -0.2            │ 279      │ 278     │
│ 3       │ 'integrated charts large scale initial load'            │ -0.1            │ 242      │ 242     │
│ 4       │ 'integrated charts large scale (load 1x legend toggle)' │ -0.1            │ 244      │ 244     │
│ 5       │                                                         │                 │          │         │
│ 6       │ 'zoom-large-dataset (load 100x zoom)'                   │ 0               │ 361      │ 361     │
│ 7       │ 'large-dataset initial load'                            │ 0.1             │ 921      │ 922     │
│ 8       │ 'large-dataset (load 1x legend toggle)'                 │ 0.1             │ 1090     │ 1091    │
│ 9       │ 'large-dataset (load 1x datum highlight)'               │ 0.3             │ 976      │ 979     │
│ 10      │ 'large-dataset (load 4x datum highlight)'               │ 0.3             │ 984      │ 987     │
└─────────┴─────────────────────────────────────────────────────────┴─────────────────┴──────────┴─────────┘

this.append(node);
return node;
}

removeChild(node: Node) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Seems odd to retain removeChild() here - but I guess this is due to the dependency from remove()?

Perhaps we could change parentNode to be of an interface type, and have Group implement that interface to break the dependency cycle whilst removing group-like behaviours from Node?

import { Node } from './node';

class TestNode<D = any> extends Node<D> {
class TestNode<D = any> extends Group<D> {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nit: Could we move tests for Group behaviours to group.test.ts rather than exercising them here still?

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.

2 participants