Commit 5739904
authored
feat: remove unnecessary copying of vector size during reversal (#5852)
# Description
## Problem\*
Resolves <!-- Link to GitHub Issue -->
## Summary\*
In order to calculate `vector_size - 1 - iterator`, rather than
initialising a register to `vector_size` and then decrementing it on
each loop iteration, we're currently recalculating it from scratch on
each iteration. I've modified this so that we can avoid these extra ops
## Additional Context
## Documentation\*
Check one:
- [x] No documentation needed.
- [ ] Documentation included in this PR.
- [ ] **[For Experimental Features]** Documentation to be submitted in a
separate PR.
# PR Checklist\*
- [x] I have tested the changes locally.
- [x] I have formatted the changes with [Prettier](https://prettier.io/)
and/or `cargo fmt` on default settings.1 parent c23463e commit 5739904
1 file changed
Lines changed: 4 additions & 10 deletions
Lines changed: 4 additions & 10 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
263 | 263 | | |
264 | 264 | | |
265 | 265 | | |
266 | | - | |
267 | | - | |
268 | | - | |
| 266 | + | |
269 | 267 | | |
| 268 | + | |
270 | 269 | | |
271 | | - | |
272 | 270 | | |
273 | | - | |
274 | | - | |
275 | | - | |
276 | | - | |
277 | | - | |
278 | | - | |
279 | 271 | | |
| 272 | + | |
| 273 | + | |
280 | 274 | | |
281 | 275 | | |
282 | 276 | | |
| |||
0 commit comments