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

Replace macro with compile-time string #3124

Open
wants to merge 7 commits into
base: main
Choose a base branch
from

Conversation

alexcristici
Copy link
Collaborator

@alexcristici alexcristici commented Jan 8, 2025

Follow-up on #3089.

Copy link

github-actions bot commented Jan 8, 2025

Bloaty Results 🐋

Compared to main

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

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

Compared to d387090 (legacy)

    FILE SIZE        VM SIZE    
 --------------  -------------- 
   +31% +36.1Mi  +438% +26.2Mi    TOTAL

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

Copy link

github-actions bot commented Jan 8, 2025

Benchmark Results ⚡

Benchmark                                                     Time             CPU      Time Old      Time New       CPU Old       CPU New
------------------------------------------------------------------------------------------------------------------------------------------
OVERALL_GEOMEAN                                            +0.0008         +0.0007             0             0             0             0

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

@alexcristici alexcristici marked this pull request as ready for review January 8, 2025 21:10
@louwers
Copy link
Collaborator

louwers commented Jan 8, 2025

Nice, thanks! I contacted the author of the code snippet. I'll update the PR with the license.

Copy link

github-actions bot commented Jan 8, 2025

Bloaty Results (iOS) 🐋

Compared to main

    FILE SIZE        VM SIZE    
 --------------  -------------- 
  -0.2% -32.0Ki  -0.2% -32.0Ki    TOTAL

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

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.

Bloaty results came back. Seems like it's not optimizing out the unused strings. So this is probably not worth it after all unless we find another approach. What do you think?

@alexcristici
Copy link
Collaborator Author

Bloaty results came back. Seems like it's not optimizing out the unused strings. So this is probably not worth it after all unless we find another approach. What do you think?

That's a big increase in size. I will try to concatenate them in the cpp, maybe this will help?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: No status
Development

Successfully merging this pull request may close these issues.

Replace macro with compile-time string in include/mbgl/shaders/mtl/collision.hpp
4 participants