Skip to content

fix: correct minimap bucket category resolution#726

Merged
lcottercertinia merged 1 commit intocertinia:mainfrom
lukecotter:fix-incorrect-minimap-bucket-colors
Feb 12, 2026
Merged

fix: correct minimap bucket category resolution#726
lcottercertinia merged 1 commit intocertinia:mainfrom
lukecotter:fix-incorrect-minimap-bucket-colors

Conversation

@lukecotter
Copy link
Copy Markdown
Contributor

@lukecotter lukecotter commented Feb 12, 2026

📝 PR Overview

Fixes incorrect category resolution in minimap density buckets by reverting a binary search optimization that caused a performance regression.

The minimap was using binary search to find frames per bucket on-demand, but this approach was slower (~90ms) than the original single-pass implementation (~10-20ms). This PR reverts to collecting frames during iteration for correct and fast category resolution.

🛠️ Changes made

  • Reverted binary search frame lookup to single-pass frame collection
  • Restored framesPerBucket array for skyline algorithm
  • Removed getFramesInRange() binary search helper
  • Updated performance documentation to reflect actual measurements

🧩 Type of change (check all applicable)

  • 🐛 Bug fix - something not working as expected
  • ⚡ Performance Improvement

🔗 Related Issues

N/A - Performance regression from recent optimization

✅ Tests added?

  • 👍 yes - added comprehensive minimap density tests

📚 Docs updated?

  • 🙅 not needed - inline documentation already updated

Anything else we need to know?

Performance measurements:

  • Before: ~90ms (binary search overhead from repeated searches)
  • After: ~10-20ms (single O(N) pass as originally intended)

The binary search optimization attempted to avoid storing frame references, but the repeated search overhead outweighed any memory benefits.

@lcottercertinia lcottercertinia merged commit b2db731 into certinia:main Feb 12, 2026
4 checks passed
@lukecotter lukecotter deleted the fix-incorrect-minimap-bucket-colors branch February 12, 2026 01:03
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