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 update time not being set when only drawable indexes are set #2743

Merged
merged 5 commits into from
Aug 27, 2024

Conversation

TimSylvester
Copy link
Collaborator

@TimSylvester TimSylvester commented Aug 21, 2024

When only a drawable's indexes are updated but not the vertex attributes, the update time wasn't set, and they were seen as out-of-date later on.

For OpenGL, changes to indexes didn't trigger an update at all, so that may have been leading to an un-detected bug. But the criteria for updates were also much too broad, so it was updating a lot when not really needed. I split up the check for building the indexes from the check for building the attributes, and saved the attribute bindings with the drawable so that they don't need to be re-built (by rebuilding the attributes) every time.

Resolves #2740

@TimSylvester TimSylvester added the bug Something isn't working label Aug 21, 2024
@TimSylvester TimSylvester self-assigned this Aug 21, 2024
Copy link

github-actions bot commented Aug 21, 2024

Bloaty Results (iOS) 🐋

Compared to main

    FILE SIZE        VM SIZE    
 --------------  -------------- 
  [ = ]       0  [ = ]       0    TOTAL

Full report: https://maplibre-native.s3.eu-central-1.amazonaws.com/bloaty-results-ios/pr-2743-compared-to-main.txt

Copy link

github-actions bot commented Aug 22, 2024

Benchmark Results ⚡

Benchmark                                                     Time             CPU      Time Old      Time New       CPU Old       CPU New
------------------------------------------------------------------------------------------------------------------------------------------
OVERALL_GEOMEAN                                            -0.0041         -0.0044             0             0             0             0

Full report: https://maplibre-native.s3.eu-central-1.amazonaws.com/benchmark-results/pr-2743-compared-to-main.txt

Copy link

github-actions bot commented Aug 22, 2024

Bloaty Results 🐋

Compared to main

    FILE SIZE        VM SIZE    
 --------------  -------------- 
  -0.0% -3.62Ki  +0.0%    +336    TOTAL

Full report: https://maplibre-native.s3.eu-central-1.amazonaws.com/bloaty-results/pr-2743-compared-to-main.txt

Compared to d387090 (legacy)

    FILE SIZE        VM SIZE    
 --------------  -------------- 
   +27% +31.0Mi  +420% +25.1Mi    TOTAL

Full report: https://maplibre-native.s3.eu-central-1.amazonaws.com/bloaty-results/pr-2743-compared-to-legacy.txt

@TimSylvester TimSylvester marked this pull request as ready for review August 23, 2024 14:12
@TimSylvester TimSylvester requested review from hy9be and removed request for hy9be August 26, 2024 16:14
Copy link
Collaborator

@louwers louwers left a comment

Choose a reason for hiding this comment

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

Would be good if @alexcristici or @mwilsnd can have a quick look as well.

Do you know why the failing assert was not triggered on CI?

@TimSylvester
Copy link
Collaborator Author

Do you know why the failing assert was not triggered on CI?

No, I can't explain that. Are you sure that asserts are enabled in the build that's running?

@louwers louwers changed the title Fix #2740 Fix update time not being set when only drawable indexes are set Aug 27, 2024
@louwers louwers merged commit 1a308dd into maplibre:main Aug 27, 2024
40 checks passed
@louwers louwers deleted the bug/2740 branch August 27, 2024 11:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

Failing assert iOS C++ Unit Tests
3 participants