Skip to content

Commit 6298419

Browse files
ValarDragonmergify[bot]
authored andcommitted
BigDec operation speedups (#8006)
* Rename precisionReuse and use squaredPrecisionReuse properly * Remove redundant copies for chop operations * Speedup RoundUpMut failed, just committing benchmark * CL notes * Speedup Truncate routines by saving ~2 word sizes * Add BigDec x Dec fns * Minor approx root spedup * Driveby, better mut usage in stableswap * Add AbsMut * Auto: update go.mod after push to dev/bigdec_speedups that modified dependencies locally --------- Co-authored-by: github-actions <github-actions@github.com> (cherry picked from commit b56059e) # Conflicts: # go.mod # go.sum # osmomath/go.mod # osmomath/go.sum # osmoutils/go.mod # osmoutils/go.sum # x/epochs/go.mod # x/epochs/go.sum # x/ibc-hooks/go.mod # x/ibc-hooks/go.sum
1 parent 0021d38 commit 6298419

File tree

17 files changed

+264
-54
lines changed

17 files changed

+264
-54
lines changed

CHANGELOG.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
4646

4747
### State Compatible
4848

49+
* [#8006](https://github.com/osmosis-labs/osmosis/pull/8006) Speedup many BigDec operations
50+
4951
## v24.0.1
5052

5153
* [#7994](https://github.com/osmosis-labs/osmosis/pull/7994) Async pruning for IAVL v1

go.mod

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,10 +30,17 @@ require (
3030
github.com/mattn/go-sqlite3 v1.14.17
3131
github.com/ory/dockertest/v3 v3.10.0
3232
github.com/osmosis-labs/go-mutesting v0.0.0-20221208041716-b43bcd97b3b3
33+
<<<<<<< HEAD
3334
github.com/osmosis-labs/osmosis/osmomath v0.0.11-0.20240409164616-caf6b6543d4b
3435
github.com/osmosis-labs/osmosis/osmoutils v0.0.11-0.20240409164616-caf6b6543d4b
3536
github.com/osmosis-labs/osmosis/x/epochs v0.0.7-0.20240409164616-caf6b6543d4b
3637
github.com/osmosis-labs/osmosis/x/ibc-hooks v0.0.13-0.20240409164616-caf6b6543d4b
38+
=======
39+
github.com/osmosis-labs/osmosis/osmomath v0.0.12-0.20240410095049-0ddea0b91fb3
40+
github.com/osmosis-labs/osmosis/osmoutils v0.0.12-0.20240410095049-0ddea0b91fb3
41+
github.com/osmosis-labs/osmosis/x/epochs v0.0.8-0.20240410095049-0ddea0b91fb3
42+
github.com/osmosis-labs/osmosis/x/ibc-hooks v0.0.14-0.20240410095049-0ddea0b91fb3
43+
>>>>>>> b56059e4 (BigDec operation speedups (#8006))
3744
github.com/osmosis-labs/sqs/sqsdomain v0.0.0-20240404053421-41aab009fb04
3845
github.com/pkg/errors v0.9.1
3946
github.com/rakyll/statik v0.1.7

go.sum

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1517,6 +1517,7 @@ github.com/osmosis-labs/cosmos-sdk v0.47.5-v24-osmo-5 h1:fnt89Cw+55vbnIEGkpCmj0c
15171517
github.com/osmosis-labs/cosmos-sdk v0.47.5-v24-osmo-5/go.mod h1:eSRUVYwL3eG1jnh01CnBbHiqOM3xJO49p5rTOrSFX1k=
15181518
github.com/osmosis-labs/go-mutesting v0.0.0-20221208041716-b43bcd97b3b3 h1:YlmchqTmlwdWSmrRmXKR+PcU96ntOd8u10vTaTZdcNY=
15191519
github.com/osmosis-labs/go-mutesting v0.0.0-20221208041716-b43bcd97b3b3/go.mod h1:lV6KnqXYD/ayTe7310MHtM3I2q8Z6bBfMAi+bhwPYtI=
1520+
<<<<<<< HEAD
15201521
github.com/osmosis-labs/osmosis/osmomath v0.0.11-0.20240409164616-caf6b6543d4b h1:hZQXid/cFL99otySUdTvbhA3Bvm7armJpg0eoYNWOVU=
15211522
github.com/osmosis-labs/osmosis/osmomath v0.0.11-0.20240409164616-caf6b6543d4b/go.mod h1:VVYCajgH7LwyzCt/5jpGLF6miIge14f+qffBnhQtHzg=
15221523
github.com/osmosis-labs/osmosis/osmoutils v0.0.11-0.20240409164616-caf6b6543d4b h1:7cMn+l3A0u38AOP9jdLW9J8ZqGCoARuu4UKvrg6xQSk=
@@ -1525,6 +1526,16 @@ github.com/osmosis-labs/osmosis/x/epochs v0.0.7-0.20240409164616-caf6b6543d4b h1
15251526
github.com/osmosis-labs/osmosis/x/epochs v0.0.7-0.20240409164616-caf6b6543d4b/go.mod h1:0Z9guabFPOQVHMNXmJ7TdqmRpEMPp4WmjztSErsFB2E=
15261527
github.com/osmosis-labs/osmosis/x/ibc-hooks v0.0.13-0.20240409164616-caf6b6543d4b h1:M+MaVJCPKMQHcZ54ODbMTyE0vPZXXtA9IopTGqRDWZY=
15271528
github.com/osmosis-labs/osmosis/x/ibc-hooks v0.0.13-0.20240409164616-caf6b6543d4b/go.mod h1:ULsY82IKYeDHry0MRMvzg/QG6wTzFLYZLhB1h+5yXUM=
1529+
=======
1530+
github.com/osmosis-labs/osmosis/osmomath v0.0.12-0.20240410095049-0ddea0b91fb3 h1:2FRCIC8gXSACn9SMmZivBXYdND/O/xrYK9rRzdY/fSY=
1531+
github.com/osmosis-labs/osmosis/osmomath v0.0.12-0.20240410095049-0ddea0b91fb3/go.mod h1:I1Nw0VK1JOaZH5f0AFl4iFB2Qp2ckbH9a3Z4UZLpDbs=
1532+
github.com/osmosis-labs/osmosis/osmoutils v0.0.12-0.20240410095049-0ddea0b91fb3 h1:dJFXQbBbMZ9UDtIMseoGlBg4fe5rSui7x3x9baAGw9w=
1533+
github.com/osmosis-labs/osmosis/osmoutils v0.0.12-0.20240410095049-0ddea0b91fb3/go.mod h1:fo3rKZIybC/tRMX09a0W/1UBl9meK1+T4PmWs1wErHI=
1534+
github.com/osmosis-labs/osmosis/x/epochs v0.0.8-0.20240410095049-0ddea0b91fb3 h1:UGxPvBFipIM8q3SJUYRjSP0+D/3Y8BkZGLvO+ov/fYs=
1535+
github.com/osmosis-labs/osmosis/x/epochs v0.0.8-0.20240410095049-0ddea0b91fb3/go.mod h1:N2+CB3wWEN/HmtWNK9DjAN1WGLgqeRiGjs+ZhK3RXdQ=
1536+
github.com/osmosis-labs/osmosis/x/ibc-hooks v0.0.14-0.20240410095049-0ddea0b91fb3 h1:QHtWt4M49bYH64Vy0DetURTtLGUIGWTpLOBIH9q/bhQ=
1537+
github.com/osmosis-labs/osmosis/x/ibc-hooks v0.0.14-0.20240410095049-0ddea0b91fb3/go.mod h1:C4/AaeluMrYxFehK61WGXVG7DvofFUyit7Xb0QKyQPA=
1538+
>>>>>>> b56059e4 (BigDec operation speedups (#8006))
15281539
github.com/osmosis-labs/sqs/sqsdomain v0.0.0-20240404053421-41aab009fb04 h1:mvkk1A/jIe+lsFFpRNfyd9UfvhagATdpnjy8K7kANeo=
15291540
github.com/osmosis-labs/sqs/sqsdomain v0.0.0-20240404053421-41aab009fb04/go.mod h1:mYYf7pYb7sGJ9zYIOw2aYlIl5cgKT0K93rZx4LvDAuA=
15301541
github.com/osmosis-labs/wasmd v0.45.0-osmo h1:NIp7pvJV5HuBN1HwPgEmXKQM2TjVIVdJErIHnB9IMO8=

0 commit comments

Comments
 (0)