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

Refactor epoch reward 4 #27261

Merged
merged 73 commits into from
Aug 22, 2022
Merged
Changes from all commits
Commits
Show all changes
73 commits
Select commit Hold shift + click to select a range
01304b9
refactor: extract store_stake_accounts fn
Aug 19, 2022
9eb7ae4
refactor: extract store_vote_account fn
Aug 19, 2022
2f14a67
refactor: extract reward history update fn
Aug 19, 2022
7bd7dd3
remove avg point value from pay_valiator fn. not used
Aug 19, 2022
4cbf643
clippy: slice
Aug 19, 2022
54dafec
merge
Aug 19, 2022
3acbc83
Merge branch 't2' into t3
Aug 19, 2022
3bbf339
Merge branch 't3' into t4
Aug 19, 2022
9508b23
clippy: slice
HaoranYi Aug 19, 2022
c062583
Merge branch 't2' into t3
HaoranYi Aug 19, 2022
99b2a7e
Merge branch 't3' into t4
HaoranYi Aug 19, 2022
f83622d
remove abort() from test-validator (#27124)
jbiseda Aug 16, 2022
a39daaa
chore: bump bytes from 1.1.0 to 1.2.1 (#27172)
dependabot[bot] Aug 16, 2022
463fc22
Share Ancestors API get with contains_key (#27161)
HaoranYi Aug 16, 2022
08bf8d3
Rename to `MAX_BLOCK_ACCOUNTS_DATA_SIZE_DELTA` (#27175)
brooksprumo Aug 16, 2022
5c796dd
chore: bump libc from 0.2.129 to 0.2.131 (#27162)
dependabot[bot] Aug 16, 2022
27ed497
reverts wide fanout in broadcast when the root node is down (#26359)
behzadnouri Aug 16, 2022
d9260d1
add getTokenLargestAccounts rpc method to rust client (#26840)
anthontaylor Aug 16, 2022
1608f90
Bump spl-token-2022 (#27181)
Aug 16, 2022
8467544
VoteProgram.safeWithdraw function to safeguard against accidental vot…
aschonfeld Aug 16, 2022
354472d
chore: bump futures from 0.3.21 to 0.3.23 (#27182)
dependabot[bot] Aug 16, 2022
490daac
chore: bump nix from 0.24.2 to 0.25.0 (#27179)
dependabot[bot] Aug 16, 2022
82f93d1
Parse ConfidentialTransaction instructions (#26825)
Aug 17, 2022
c76807a
snapshots: serialize version file first (#27192)
apfitzge Aug 17, 2022
ce40986
serialize incremental_snapshot_hash (#26839)
jeffwashington Aug 17, 2022
4e7bc0f
derives Error trait for ClusterInfoError and core::result::Error (#27…
behzadnouri Aug 17, 2022
a92758b
Add clean_accounts_for_tests() (#27200)
brooksprumo Aug 17, 2022
f76e499
Rust v1.63.0 (#27148)
bw-solana Aug 17, 2022
6b7437c
docs: updated "transaction fees" page (#26861)
nickfrosty Aug 18, 2022
62e8765
sdk: Fix args after "--" in build-bpf and test-bpf (#27221)
joncinque Aug 18, 2022
ac6ab90
Flaky Unit Test test_rpc_subscriptions (#27214)
bw-solana Aug 18, 2022
27c9191
chore: only buildkite pipelines use sccache in docker-run.sh (#27204)
yihau Aug 18, 2022
2f51fa3
clean feature: `prevent_calling_precompiles_as_programs` (#27100)
jstarry Aug 18, 2022
5060e3a
Add get_account_with_commitment to BenchTpsClient (#27176)
Aug 18, 2022
1524aa7
Fix a corner-case panic in get_entries_in_data_block() (#27195)
yhchiang-sol Aug 18, 2022
76b7384
Verify snapshot slot deltas (#26666)
brooksprumo Aug 18, 2022
ad9d44a
store-tool: log lamports for each account (#27168)
apfitzge Aug 18, 2022
36fea44
add an assert for a debug feature to avoid wasted time (#27210)
jeffwashington Aug 18, 2022
19fa32b
remove redundant call that bumps age to future (#27215)
jeffwashington Aug 18, 2022
9c94ca3
Use from_secs api to create duration (#27222)
HaoranYi Aug 18, 2022
979da4e
reorder slot # in debug hash data path (#27217)
jeffwashington Aug 18, 2022
83b31bd
create helper fn for clarity (#27216)
jeffwashington Aug 18, 2022
e09fa39
Verifying snapshot bank must always specify the snapshot slot (#27234)
brooksprumo Aug 18, 2022
cfab5c5
Remove `Bank::ensure_no_storage_rewards_pool()` (#26468)
brooksprumo Aug 18, 2022
471ae90
cli: Add subcommands for address lookup tables (#27123)
jstarry Aug 18, 2022
da75405
adds hash domain to ping-pong protocol (#27193)
behzadnouri Aug 18, 2022
f727653
Revert "Rust v1.63.0 (#27148)" (#27245)
bw-solana Aug 19, 2022
6436a68
correct double negation (#27240)
leonardkulms Aug 19, 2022
58cd2d3
Enable QUIC client by default. Add arg to disable QUIC client. (Forwa…
willhickey Aug 19, 2022
d940c6e
slots_connected: check if the range is connected (>= ending_slot) (#2…
apfitzge Aug 19, 2022
e12955e
create-snapshot check if snapshot slot exists (#27153)
apfitzge Aug 19, 2022
c9d7ad0
Add Bank::clean_accounts_for_tests() (#27209)
brooksprumo Aug 19, 2022
27e2d51
Call `AccountsDb::shrink_all_slots()` directly (#27235)
brooksprumo Aug 19, 2022
44b8eac
add ed25519_program to built-in instruction cost list (#27199)
tao-stones Aug 19, 2022
1cebb1f
simple refactorings to disk idx (#27238)
jeffwashington Aug 19, 2022
437387d
add _inclusive for clarity (#27239)
jeffwashington Aug 19, 2022
bbf622c
eliminate unnecessary ZERO_RAW_LAMPORTS_SENTINEL (#27218)
jeffwashington Aug 19, 2022
f94f12a
make test code more clear (#27260)
jeffwashington Aug 19, 2022
0721fe6
banking stage: actually aggregate tracer packet stats (#27118)
apfitzge Aug 19, 2022
14aaf79
Refactor epoch reward 1 (#27253)
HaoranYi Aug 19, 2022
94adb77
recovers merkle shreds from erasure codes (#27136)
behzadnouri Aug 19, 2022
aa2a286
Simplify `Bank::clean_accounts()` by removing params (#27254)
brooksprumo Aug 19, 2022
5c856b3
Account files remove (#26910)
xiangzhu70 Aug 20, 2022
9e769fb
Refactor: Flattens `TransactionContext::instruction_trace` (#27109)
Lichtso Aug 20, 2022
4b4af89
Parallel insertion of dirty store keys during clean (#27058)
bw-solana Aug 20, 2022
2f0d355
Refactor epoch reward 2 (#27257)
HaoranYi Aug 20, 2022
e399b11
Standardize thread names
mvines Aug 17, 2022
c63453f
cleanup comment on filter_zero_lamport_clean_for_incremental_snapshot…
jeffwashington Aug 20, 2022
3a80118
remove inaccurate log (#27255)
jeffwashington Aug 20, 2022
bdf3735
patches metrics for invalid cached vote/stake accounts (#27266)
behzadnouri Aug 20, 2022
bac5297
Refactor epoch reward 3 (#27259)
HaoranYi Aug 21, 2022
ea4a219
fix merges
Aug 21, 2022
f038d67
merge
Aug 21, 2022
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 2 additions & 3 deletions runtime/src/bank.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3059,7 +3059,7 @@ impl Bank {
thread_pool: &ThreadPool,
metrics: &mut RewardsMetrics,
update_rewards_from_cached_accounts: bool,
) -> f64 {
) {
let stake_history = self.stakes_cache.stakes().history().clone();
let vote_with_stake_delegations_map = {
let mut m = Measure::start("load_vote_and_stake_accounts_us");
Expand Down Expand Up @@ -3125,7 +3125,7 @@ impl Bank {
metrics.calculate_points_us.fetch_add(m.as_us(), Relaxed);

if points == 0 {
return 0.0;
return;
}

// pay according to point value
Expand Down Expand Up @@ -3212,7 +3212,6 @@ impl Bank {
self.store_stake_accounts(&stake_rewards, metrics);
let vote_rewards = self.store_vote_accounts(vote_account_rewards, metrics);
self.update_reward_history(stake_rewards, vote_rewards);
point_value.rewards as f64 / point_value.points as f64
}

fn store_stake_accounts(&self, stake_rewards: &[StakeReward], metrics: &mut RewardsMetrics) {
Expand Down