Commit Graph

23164 Commits

Author SHA1 Message Date
dependabot[bot] eb380bead9
Bump js-sys from 0.3.63 to 0.3.64 (#32089)
* Bump js-sys from 0.3.63 to 0.3.64

Bumps [js-sys](https://github.com/rustwasm/wasm-bindgen) from 0.3.63 to 0.3.64.
- [Release notes](https://github.com/rustwasm/wasm-bindgen/releases)
- [Changelog](https://github.com/rustwasm/wasm-bindgen/blob/main/CHANGELOG.md)
- [Commits](https://github.com/rustwasm/wasm-bindgen/commits)

---
updated-dependencies:
- dependency-name: js-sys
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

* [auto-commit] Update all Cargo lock files

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: dependabot-buildkite <dependabot-buildkite@noreply.solana.com>
2023-06-19 12:52:37 -06:00
dependabot[bot] 7cd3c1e8a6
Bump wasm-bindgen from 0.2.86 to 0.2.87 (#32120)
* Bump wasm-bindgen from 0.2.86 to 0.2.87

Bumps [wasm-bindgen](https://github.com/rustwasm/wasm-bindgen) from 0.2.86 to 0.2.87.
- [Release notes](https://github.com/rustwasm/wasm-bindgen/releases)
- [Changelog](https://github.com/rustwasm/wasm-bindgen/blob/main/CHANGELOG.md)
- [Commits](https://github.com/rustwasm/wasm-bindgen/compare/0.2.86...0.2.87)

---
updated-dependencies:
- dependency-name: wasm-bindgen
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

* [auto-commit] Update all Cargo lock files

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: dependabot-buildkite <dependabot-buildkite@noreply.solana.com>
2023-06-19 12:52:25 -06:00
dependabot[bot] 66040df0fa
Bump proc-macro2 from 1.0.59 to 1.0.60 (#32027)
* Bump proc-macro2 from 1.0.59 to 1.0.60

Bumps [proc-macro2](https://github.com/dtolnay/proc-macro2) from 1.0.59 to 1.0.60.
- [Release notes](https://github.com/dtolnay/proc-macro2/releases)
- [Commits](https://github.com/dtolnay/proc-macro2/compare/1.0.59...1.0.60)

---
updated-dependencies:
- dependency-name: proc-macro2
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

* [auto-commit] Update all Cargo lock files

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: dependabot-buildkite <dependabot-buildkite@noreply.solana.com>
2023-06-19 12:51:06 -06:00
dependabot[bot] 96319dbc94
Bump log from 0.4.18 to 0.4.19 (#32070)
* Bump log from 0.4.18 to 0.4.19

Bumps [log](https://github.com/rust-lang/log) from 0.4.18 to 0.4.19.
- [Release notes](https://github.com/rust-lang/log/releases)
- [Changelog](https://github.com/rust-lang/log/blob/master/CHANGELOG.md)
- [Commits](https://github.com/rust-lang/log/compare/0.4.18...0.4.19)

---
updated-dependencies:
- dependency-name: log
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

* [auto-commit] Update all Cargo lock files

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: dependabot-buildkite <dependabot-buildkite@noreply.solana.com>
2023-06-19 12:10:57 -06:00
Alessandro Decina 8757f8df73
programs/sbf: c/float: work on stack values (#32192)
Before this change the program was writing into the realloc region.
Direct mapping is going to  enforce permissions on the realloc region,
and the program doesn't have permissions to write, so move to working on
the stack to avoid access violation errors.
2023-06-19 18:04:19 +02:00
samkim-crypto 875b95a07b
[zk-token-proof] Add benches for proof instructions (#32071)
* add bench test for `VerifyPubkeyValidity`

* add bench test for `VerifyRangeProofU64`

* add bench test for `VerifyWithdraw`

* add bench test for `VerifyZeroBalance`

* add bench test for `VerifyGroupedCiphertextValidity`

* add bench test for `VerifyCiphertextCommitmentEquality`

* add bench test for `VerifyCiphertextCiphertextEquality`

* add bench test for `VerifyBatchedGroupedCiphertextValidity`

* add bench test for `VerifyBatchedRangeProofu64`, `VerifyBatchedRangeProofU128`, `VerifyBatchedRangeProofU256`

* add bench test for `VerifyTransfer` and `VerifyTransferWithFee`

* use add `criterion` to workspace cargo

* add bench to ci
2023-06-18 07:52:20 +09:00
samkim-crypto 428283c9ef
[zk-token-sdk] Refactor pod `FeeParameters` conversion and remove manual byte conversion for the type (#32149)
* replace `decoded::TransferAmountCiphertext` to `DecodedTransferAmountCiphertext`

* refactor pod convert logic for fee parameters

* remove manual byte conversions for `FeeParameters`

* fix error from rebase
2023-06-18 07:51:49 +09:00
Brooks de024bf98d
Adds `--boot-from-local-state` to validator (#32168) 2023-06-16 16:29:04 -04:00
galactus 2ceabd9368
Simd 47 syscall sysvar last restart slot (#31957)
* add sysvar and logic for last restart slot

* cleanup

* add test for getting last restart slot from account

* format code

* add some basic rustdoc

* copy+paste error

* feature flag for last_restart_slot

* add to sysvars.md

* updated wording in sysvars.md

* rename sol_get_last_restart_slot_sysvar > sol_get_last_restart_slot

* create sbf C header for sol_get_last_restart_slot

* cleanup imports

* reverted hardened_unpack workaround

* cleanup imports

* cleanup logs + blank lines

* Implementing ui changes for last restart slot, nit

* Some more nit change and implementing the UI for sysvar

* fixing the CI

* Minor clippy fix

* format changes

* changes suggested by mvines and lichtso

* increase timeout in local_cluster test

* fix code format

* use keypair for feature flag from mvines

* delete test.json file

* Revert "increase timeout in local_cluster test"

This reverts commit a67465ae22.

* last restart slot should be always less than or equal to current slot

* fixing bug

* changes after  steviez comments

* format issue fixed

* fixing the comment on premature application of future hardfork

* nit change in test

Co-authored-by: steviez <steven@solana.com>

* reverting sysvar_cache.rs because change was not necessary

---------

Co-authored-by: steve-gg <grooviegermanikus@gmail.com>
Co-authored-by: steviez <steven@solana.com>
2023-06-16 20:14:02 +00:00
behzad nouri 987e8eeeaf
removes feature gate code dropping redundant turbine path (#32075) 2023-06-16 19:53:05 +00:00
Jeff Washington (jwash) 174ceba82b
rename to stake_rewards_by_partition for clarity (#32165) 2023-06-16 19:28:53 +00:00
Brooks f720ca3339
`bank_forks_from_snapshot()` always returns starting snapshot hashes (#32178) 2023-06-16 14:38:03 -04:00
Brooks 2aac9fca35
Adds --boot-from-local-state to ledger-tool create-snapshot (#32032) 2023-06-16 12:58:57 -04:00
HaoranYi 39d9f8974d
Revert "add test for is_partitioned_rewards_feature_enabled (#32158)" (#32176)
This reverts commit d06b099ecb.

Co-authored-by: HaoranYi <haoran.yi@solana.com>
2023-06-16 11:56:05 -05:00
HaoranYi d06b099ecb
add test for is_partitioned_rewards_feature_enabled (#32158)
* add set_partitioned_rewards_enabled_for_test fn

* reveiws

---------

Co-authored-by: HaoranYi <haoran.yi@solana.com>
2023-06-16 11:07:07 -05:00
HaoranYi ec9fdbf2c3
Add epoch reward feature id (#32051)
* add epoch reward feature id

* add feature gate issue id

---------

Co-authored-by: HaoranYi <haoran.yi@solana.com>
2023-06-16 08:41:08 -05:00
HaoranYi af7b7f1436
Refactor reward block calculation fn (#32167)
refactor reward block calculation fn

Co-authored-by: HaoranYi <haoran.yi@solana.com>
2023-06-16 08:40:23 -05:00
samkim-crypto 37f51e8376
[zk-token-sdk] Define `FeeEncryption` as a wrapper around `GroupedElGamalCiphertext` (#32144)
* define `FeeEncryption` as a wrapper around `GroupedElGamalCiphertext`

* define pod `FeeEncryption` as a wrapper around `GroupedElGamalCiphertext2Handles`

* update proof data computation

* add comments about unwraps
2023-06-16 17:53:36 +09:00
Brooks 47ff3cecc9
Enables creating snapshots after booting from local state (#32137) 2023-06-15 22:54:32 -04:00
Jeff Washington (jwash) b1b7ae5e09
cleanup math in distribute_partitioned_epoch_rewards (#32164) 2023-06-15 16:17:38 -07:00
Jeff Washington (jwash) b4265217e6
update begin_partitioned_rewards to include sysvar (#32151)
* update begin_partitioned_rewards to include sysvar

* cleanup
2023-06-15 14:00:24 -07:00
Andrew Fitzgerald a875562ccd
Funding transactions must specify data limit (#32131) 2023-06-15 18:53:04 +00:00
Jeff Washington (jwash) d79b565c72
connect `begin_partitioned_rewards` to bank (#32152) 2023-06-15 11:51:10 -07:00
Andrew Fitzgerald 90812fac76
bench-tps tests use bank w/ all features enabled (#32142) 2023-06-15 17:38:39 +00:00
Ashwin Sekar 01d3546de0
Increment timestamp on refreshed votes (#31908) 2023-06-15 10:38:22 -07:00
Jeff Washington (jwash) e7a676dc01
add distribute_partitioned_epoch_rewards (#32124)
* add distribute_partitioned_epoch_rewards

* reviews

* reanme

---------

Co-authored-by: HaoranYi <haoran.yi@solana.com>
2023-06-15 11:32:44 -05:00
Jeff Washington (jwash) 988bff93c8
deactivate_epoch_rewards_status burns sysvar (#32143)
* deactivate_epoch_reward_status burns sysvar

* warn to info

---------

Co-authored-by: HaoranYi <haoran.yi@solana.com>
2023-06-15 10:36:50 -05:00
Raza eabe107066
[docs] Add beginner-friendly intro to Solana guide (#31861)
* Docs: Create intro to Solana guide

* Docs: Fix formatting on getstarted/overview

* Docs: Fix linter errors on getstarted/overview
2023-06-14 21:35:19 -05:00
Jon Cinque bd4196b084
Revert "Bump borsh from 0.10.3 to 0.11.0 (#31964)" (#32145)
This reverts commit 902d8b73fe.
2023-06-15 02:36:37 +02:00
hana b60d12418f
impl Signers for Arc<dyn Signer> arrays (#32136) 2023-06-14 17:20:09 -07:00
Jeff Washington (jwash) 00b5c40122
add partitioned rewards sysvar fns (#32128) 2023-06-14 16:08:15 -07:00
Brooks ae65b35d9b
Removes StakeInstruction::GetMinimumDelegation featurization (#32121) 2023-06-14 19:01:17 -04:00
hana 11f331764e
derive Clone for OutputFormat in cli-output (#32138) 2023-06-14 15:22:23 -07:00
Trent Nelson 26be1a3a0c
ci: discard misleading `cargo uninstall` errors in bk post-checkout hook (#32139) 2023-06-14 16:01:48 -06:00
Jeff Washington (jwash) 60e36afd42
add begin_partitioned_rewards (#32116)
* add begin_partitioned_rewards

* pr feedback

* Apply suggestions from code review

Co-authored-by: Brooks <brooks@prumo.org>

---------

Co-authored-by: HaoranYi <haoran.yi@gmail.com>
Co-authored-by: Brooks <brooks@prumo.org>
2023-06-14 14:24:49 -07:00
Tao Zhu 4b30454193
bench-tps add 1_000 as multiplier to compute-unit-price (#32132)
add 1_000 as multiplier to compute-unit-price
2023-06-14 14:50:18 -05:00
Jeff Washington (jwash) 088ac5ec01
add is_partitioned_rewards_code_enabled (#32123)
* add partitioned_rewards_code_enabled

* renames
2023-06-14 14:36:53 -05:00
Tao Zhu e83a06d85e
set Transfer transaction loaded_accounts_data_size in bench-tps (#32105)
* set Transfer transaction loaded_accounts_data_size in bench-tps

* increase compute_unit_limit for additional ix
2023-06-14 13:30:43 -05:00
Brooks 8b25052978
Removes unnecessary call to `purge_old_bank_snapshots()` in local-cluster test (#32111) 2023-06-14 14:11:35 -04:00
Jeff Washington (jwash) f487dfbc77
add distribute_epoch_rewards_in_partition (#32125) 2023-06-14 11:03:17 -07:00
Jeff Washington (jwash) a1ce3cbaa3
partitioned rewards fn for tests: force_reward_interval_end_for_tests (#32127)
partitioned rewards fn for tests
2023-06-14 10:59:48 -07:00
Jeff Washington (jwash) 4eb7db8737
in testing, hash_internal_state ignores epoch_rewards_sysvar (#32122) 2023-06-14 10:57:29 -07:00
Jeff Washington (jwash) 9cf10b7aae
optionally compare with partitioned rewards (#32126) 2023-06-14 10:55:09 -07:00
CanardMandarin 2b5594a409
Fix minimum balance when deploying program (#32129) 2023-06-14 17:44:20 +00:00
Jeff Washington (jwash) c01250fc58
add calculate_rewards_and_distribute_vote_rewards (#32109)
* add calculate_rewards_and_distribute_vote_rewards

* warn -> info
2023-06-14 08:38:25 -07:00
Jeff Washington (jwash) a44b080b7f
add partitioned_rewards_feature_enabled (#32115) 2023-06-14 07:47:12 -07:00
Jeff Washington (jwash) 1fa73e778f
add deactivate_epoch_reward_status (#32114) 2023-06-14 07:46:34 -07:00
Jeff Washington (jwash) 2968587d42
add compare_with_partitioned_rewards (#32108) 2023-06-14 07:43:09 -07:00
HaoranYi ffe4c06a19
Add epoch_reward sysvar (#32049)
* Add epoch_reward sysvar

* Apply suggestions from code review

Co-authored-by: Brooks <brooks@prumo.org>

* remove new from EpochRewards

* remove copy test

* Apply suggestions from code review

Co-authored-by: Jon Cinque <joncinque@pm.me>
Co-authored-by: Tyera <teulberg@gmail.com>

* reviews

---------

Co-authored-by: HaoranYi <haoran.yi@solana.com>
Co-authored-by: Brooks <brooks@prumo.org>
Co-authored-by: Jon Cinque <joncinque@pm.me>
Co-authored-by: Tyera <teulberg@gmail.com>
2023-06-14 08:41:26 -05:00
Alexander Meißner 3b0b0ba07d
Cleanup - filter_votes_outside_slot_hashes (#31760)
filter_votes_outside_slot_hashes
2023-06-14 01:31:27 +02:00