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

ArrayTile.{cols | rows} calls boxing fix #3441

Merged
merged 1 commit into from
Dec 3, 2021

Conversation

pomadchin
Copy link
Member

@pomadchin pomadchin commented Dec 3, 2021

Overview

Since GT 3.x we had a regression where all calls to cols / rows were boxed. This lead to regressions in MutableArrayTile.{set / update / etc} functions. For more details see #3427, #3428, #3429 and #3432

This PR clarifies Grid inheritors cols / rows function types to help with the specialized calls dispatch.

Checklist

  • ./CHANGELOG.md updated, if necessary. Link to the issue if closed, otherwise the PR.
  • Benchmark added for bug-fix or new feature

Demo

Can be reproduced via:

$ sbt project bench; benchOnly geotrellis/raster/GridBoxingBench.scala

Screen Shot 2021-12-02 at 21 52 48

Closes #3427
Closes #3432

@pomadchin pomadchin changed the title ArrayTile.cols()/rows() calls boxing fix ArrayTile.{cols()/rows() calls boxing fix Dec 3, 2021
@pomadchin pomadchin changed the title ArrayTile.{cols()/rows() calls boxing fix ArrayTile.{cols | rows} calls boxing fix Dec 3, 2021
@pomadchin pomadchin force-pushed the fix/boxing-regression branch 2 times, most recently from fecddae to f1c266a Compare December 3, 2021 03:04
@pomadchin pomadchin force-pushed the fix/boxing-regression branch from f1c266a to c949a9a Compare December 3, 2021 03:31
@pomadchin pomadchin merged commit fa62e3a into locationtech:master Dec 3, 2021
@pomadchin pomadchin deleted the fix/boxing-regression branch December 3, 2021 18:17
@pomadchin
Copy link
Member Author

Going to leave here a link to this repo, for history https://github.com/pomadchin/specialization-benchmark

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.

ShortUserDefinedNoDataArrayTile.cols()/rows() calls scala/runtime/BoxesRunTime.boxToInteger
3 participants