Commit Graph

15216 Commits

Author SHA1 Message Date
fc8f61368d Revert "Added vote limits to be 75% of total block limit"
This reverts commit 3e131a5324.
2022-01-18 15:10:49 -07:00
aabcdcf8fb Add execute metrics (backport #22296) (#22334)
* consolidate execute timings to a common module

* Add execute metrics

* Add metrics for executor creation

* Use saturating_add_assign macro

Co-authored-by: Trent Nelson <trent@solana.com>
Co-authored-by: Carl Lin <carl@solana.com>
2022-01-18 19:18:24 +00:00
81e65eae0b Use VecDeque instead of Vec in sigverify stage (#22538) (#22549)
avoid bad performance of remove(0) for a single sender

(cherry picked from commit 49443406fd)

# Conflicts:
#	core/src/sigverify_stage.rs

Co-authored-by: sakridge <sakridge@gmail.com>
2022-01-17 22:19:25 +00:00
38e72982bc metrics for generate new bank forks (#22492) (#22547)
* metrics for generate new bank forks

* fixed

* Apply suggestions from code review

Co-authored-by: Trent Nelson <trent.a.b.nelson@gmail.com>

* --fixup

* fixup!

Co-authored-by: Trent Nelson <trent.a.b.nelson@gmail.com>
(cherry picked from commit 2d94e6e5d3)

# Conflicts:
#	core/src/replay_stage.rs

Co-authored-by: anatoly yakovenko <anatoly@solana.com>
2022-01-17 21:48:20 +00:00
d52dd97ad1 log internals (#22493) (#22496)
(cherry picked from commit eca8d21249)

Co-authored-by: carllin <carl@solana.com>
2022-01-15 05:22:08 +00:00
61f88e04d2 adds methods to obtain shreds' erasure coded block and index (#21325) (#22508)
(cherry picked from commit 7da2df7d8c)

Co-authored-by: behzad nouri <behzadnouri@gmail.com>
2022-01-14 17:43:16 +00:00
3e131a5324 Added vote limits to be 75% of total block limit 2022-01-14 10:49:17 -06:00
5655ea0061 count vote transaction units to block cost 2022-01-14 10:49:17 -06:00
40ef11ec86 implements copy-on-write for staked-nodes (backport #19090) (#22507)
* implements copy-on-write for staked-nodes (#19090)

Bank::staked_nodes and Bank::epoch_staked_nodes redundantly clone
staked-nodes HashMap even though an immutable reference will suffice:
https://github.com/solana-labs/solana/blob/a9014cece/runtime/src/vote_account.rs#L77

This commit implements copy-on-write semantics for staked-nodes by
wrapping the underlying HashMap in Arc<...>.

(cherry picked from commit f302774cf7)

# Conflicts:
#	runtime/src/bank.rs
#	runtime/src/stakes.rs
#	runtime/src/vote_account.rs

* removes backport merge conflicts

Co-authored-by: behzad nouri <behzadnouri@gmail.com>
2022-01-14 15:26:11 +00:00
debac00724 Soften vote account identity mismatch from panic to runtime error 2022-01-13 19:31:03 -08:00
304afd42c6 Revert "Stop caching sysvars, instead load them ahead of time (backport #21108) (#22466)"
This reverts commit 5d3f3bc9b1.
2022-01-14 11:13:04 +08:00
5d3f3bc9b1 Stop caching sysvars, instead load them ahead of time (backport #21108) (#22466)
* Stop caching sysvars, instead load them ahead of time. (#21108)

(cherry picked from commit 29ad081555)

# Conflicts:
#	programs/bpf/tests/programs.rs
#	programs/bpf_loader/src/syscalls.rs
#	programs/stake/src/stake_instruction.rs
#	runtime/src/bank.rs
#	runtime/src/message_processor.rs
#	sdk/program/src/sysvar/mod.rs
#	sdk/src/process_instruction.rs

* resolve conflicts

Co-authored-by: Alexander Meißner <AlexanderMeissner@gmx.net>
Co-authored-by: Justin Starry <justin@solana.com>
2022-01-13 17:51:13 +00:00
42531a11a5 limits gossip vote stats to the top most voted slots (#22416) (#22473)
(cherry picked from commit 49da347d84)

Co-authored-by: behzad nouri <behzadnouri@gmail.com>
2022-01-13 16:23:42 +00:00
10c40c9c2d Remove program-runtime/src/invoke_context.rs 2022-01-13 23:59:02 +08:00
1ef48f369e downgrade individual per-program-timing to trace to reduce writes to influx
(cherry picked from commit 6614727be8)
2022-01-12 22:01:56 -06:00
05e75ae937 Don't forward packets received from TPU forwards port (backport #22078) (#22180)
* Don't forward packets received from TPU forwards port (#22078)

* resolve conflicts
2022-01-10 14:36:56 +08:00
a7aa5202ab bank: fix executor cache metrics (#22395)
(cherry picked from commit 3b4aad9df1)

Co-authored-by: Trent Nelson <trent@solana.com>
2022-01-09 05:55:08 +00:00
9aa7821277 Bump version to v1.8.13 2022-01-08 12:27:11 -07:00
fee86726f2 improve multi executor cache addition (#22381)
(cherry picked from commit 4a9f4e2505)

Co-authored-by: Jack May <jack@solana.com>
v1.8.12
2022-01-08 12:52:16 +00:00
8a470d3ae8 add excutor creation trace timings 2022-01-08 04:46:31 -07:00
8c6df1f234 bank: prime new executor cache entry use-counts (#22374)
Co-authored-by: Trent Nelson <trent@solana.com>
2022-01-08 10:14:05 +00:00
7cbfab0958 remove per program timings from blockstore processor ledger replay (#22370) (#22371)
(cherry picked from commit 813006b33b)

Co-authored-by: carllin <carl@solana.com>
2022-01-08 08:33:31 +00:00
6130466a21 Executor cache metrics (backport #22332) (#22367)
* Add helper macro for `AddAssign`ing with saturating arithmetic

* bank: Add executors cache metrics

Co-authored-by: Trent Nelson <trent@solana.com>
2022-01-08 02:19:36 +00:00
299a59f458 removes CowCachedExecutors (backport #22343) (#22362)
* removes CowCachedExecutors (#22343)

Copy-on-write semantics for cached executors can be implemented by a
simple Arc<CachedExecutors> as opposed to CowCachedExecutors:
https://github.com/solana-labs/solana/blob/f1e2598ba/runtime/src/bank.rs#L244-L247

This will also avoid the need for double locking as in:
https://github.com/solana-labs/solana/blob/f1e2598ba/runtime/src/bank.rs#L3490-L3491
https://github.com/solana-labs/solana/blob/f1e2598ba/runtime/src/bank.rs#L3525-L3526

(cherry picked from commit c2389fc209)

# Conflicts:
#	runtime/src/bank.rs

* removes backport merge conflicts

Co-authored-by: behzad nouri <behzadnouri@gmail.com>
2022-01-07 16:18:00 +00:00
b30c726d22 Add aarch64-apple-darwin publish tarball step (#22355)
(cherry picked from commit e2aa932e97)

Co-authored-by: Michael Vines <mvines@gmail.com>
2022-01-07 10:13:46 +00:00
069bb5e32f Increase timeout of local-cluster-slow CI step 2022-01-07 15:31:28 +08:00
cad0e7f04f cache executors on failed transactions (backport #22308) (#22327)
* cache executors on failed transactions (#22308)

(cherry picked from commit 12e160269e)

# Conflicts:
#	program-runtime/src/invoke_context.rs
#	programs/bpf_loader/src/lib.rs
#	runtime/src/bank.rs

* resolve conflicts

Co-authored-by: Jack May <jack@solana.com>
2022-01-06 15:38:39 -08:00
c90fa6643e Retain executor cache counts (#22322) (#22340)
(cherry picked from commit f1e2598baa)

Co-authored-by: Jack May <jack@solana.com>
2022-01-06 19:11:05 +00:00
54db774203 Split up local cluster tests into separate CI steps (backport #22295) (#22302)
* Split up local cluster tests into separate CI steps (#22295)

* Split up local cluster tests into separate CI steps

* Update buildkite-pipeline.sh

(cherry picked from commit 0e1afcbb26)

# Conflicts:
#	local-cluster/tests/local_cluster.rs

* resolve conflicts

Co-authored-by: Justin Starry <justin@solana.com>
2022-01-06 15:26:56 +00:00
57b5ce5731 [ledger-tool]compare_blocks (#22229) (#22329)
* 1.made load_credentials accept credential path as a parameter. 2.partial implement bigtable comparasion function

* finding missing blocks in bigtables in a specified range

* refactor compare-blocks,add unit test for missing_blocks and fmt

* compare-block fix last block bug

* refactor compare-block and improve wording

* Update ledger-tool/src/bigtable.rs

Co-authored-by: Tyera Eulberg <teulberg@gmail.com>

* update compare-block command-line description

* style:improve wording/naming/code style

Co-authored-by: Tyera Eulberg <teulberg@gmail.com>
(cherry picked from commit d9220652ad)

Co-authored-by: pieceofr <komimi.p@gmail.com>
2022-01-06 08:47:08 +00:00
e0d933f940 perf: skip updating already cached executors if unmodified (backport #22300) (#22315)
* Skip updating already cached executors if unmodified

(cherry picked from commit f2ed6f09ee)

# Conflicts:
#	program-runtime/src/invoke_context.rs
#	runtime/src/bank.rs

* resolve conflicts

Co-authored-by: Justin Starry <justin@solana.com>
2022-01-06 02:04:55 +00:00
e2559f20df fix(rpc): recreate dead and uncleaned subscriptions (#22281) (#22293)
(cherry picked from commit c1995c647b)

Co-authored-by: Nikita <bananaelecitrus@gmail.com>
2022-01-05 10:23:34 +00:00
7b9ca3e9d9 Flip iter operations to keep associated address/header/packets together (backport #22245) (#22256)
* Flip iter operations to keep associated address/header/packets together (#22245)

Flip iter operations to keep associated address/header/packets together

Before this change, if cast_socket_addr() returned a None for any
address/header pair, the subsequent zip() would misalign the
address/header pair and packet. So, this change zips all three together,
then does filter_map() so keep things aligned.

Additionally, compute total_size inline to avoid running through packets
a second time.

(cherry picked from commit 20b61e28b6)

# Conflicts:
#	streamer/src/recvmmsg.rs

* removes backport merge conflicts

Co-authored-by: steviez <steven@solana.com>
Co-authored-by: behzad nouri <behzadnouri@gmail.com>
2022-01-04 16:31:59 +00:00
f0de9b43be Lower vote-only-mode to 400 (#22210) (#22271)
(cherry picked from commit 2486e21ffe)

Co-authored-by: sakridge <sakridge@gmail.com>
2022-01-04 14:17:31 +00:00
6d7b64b140 Fix bug, add error specific timings (#22225) (#22251)
(cherry picked from commit 005592998d)

Co-authored-by: carllin <carl@solana.com>
2022-01-04 09:23:49 +00:00
f506851ca1 removes epoch_authorized_voters from VoteTracker (backport #22192) (#22250)
* removes epoch_authorized_voters from VoteTracker (#22192)

https://github.com/solana-labs/solana/pull/22169
verifies authorized-voter early on in vote-listener pipeline; and so
VoteTracker no longer needs to maintain and check for epoch authorized
voters.

(cherry picked from commit 69d71f8f86)

# Conflicts:
#	core/src/cluster_info_vote_listener.rs

* removes backport merge conflicts

Co-authored-by: behzad nouri <behzadnouri@gmail.com>
2022-01-04 02:02:56 +00:00
b70113e201 Correctly set CI_COMMIT when Buildkite provides HEAD instead of a real commit 2022-01-03 17:40:35 -08:00
6093c7a218 Switch from arm64-apple-darwin to aarch64-apple-darwin to align with Rust's target names 2022-01-03 17:27:09 -08:00
b9777e10ee Add support for arm64-apple-darwin release/channel artifacts 2022-01-03 17:27:05 -08:00
d840d56565 Use experimential docker virtualization framework for arm64
(cherry picked from commit ed0b47c6f8)
2022-01-03 17:27:00 -08:00
afb8df0c62 Correctly set CI_OS_NAME for macOs buildkite agents 2022-01-03 17:26:54 -08:00
84d535b89e re-calibrate limit based on mainnet data (backport #21995) (#22211)
* re-calibrate limit based on mainnet data, see issue #21917

(cherry picked from commit d743c2917c)

# Conflicts:
#	runtime/src/block_cost_limits.rs

* set secp256k1 cost similar to sigverify

(cherry picked from commit a2a7e91ad6)

* removes backport merge conflicts

Co-authored-by: Tao Zhu <tao@solana.com>
2022-01-03 19:03:41 +00:00
de1a9f84ac Bump rbpf to v0.2.21 (#22216) (#22218)
(cherry picked from commit 9139be89b7)
2022-01-01 21:43:28 +00:00
22bbd91843 Count compute units even when transaction errors (backport #22182) (#22198)
* Resolve conflicts

* Return err

Co-authored-by: carllin <carl@solana.com>
2022-01-01 13:16:56 +00:00
1babd07faf Increment execution timings on errors as well (backport #22053) (#22071)
* Increment execution timings on errors as well (#22053)

(cherry picked from commit 37f6777ceb)

# Conflicts:
#	programs/bpf_loader/src/lib.rs

* Fix conflicts

Co-authored-by: carllin <carl@solana.com>
2022-01-01 13:04:34 +00:00
0592b5568f Bump local cluster timeout (#22214) 2022-01-01 06:02:38 -05:00
ce98feac4e Exit early on BigTable error (#22200) (#22208)
(cherry picked from commit 0b1b36f088)

Co-authored-by: Tyera Eulberg <teulberg@gmail.com>
2022-01-01 02:05:36 +00:00
a53dd611c0 uses enum for shred type (backport #21333) (#22147)
* uses enum for shred type

Current code is using u8 which does not have any type-safety and can
contain invalid values:
https://github.com/solana-labs/solana/blob/66fa062f1/ledger/src/shred.rs#L167

Checks for invalid shred-types are scattered through the code:
https://github.com/solana-labs/solana/blob/66fa062f1/ledger/src/blockstore.rs#L849-L851
https://github.com/solana-labs/solana/blob/66fa062f1/ledger/src/shred.rs#L346-L348

The commit uses enum for shred type with #[repr(u8)]. Backward
compatibility is maintained by implementing Serialize and Deserialize
compatible with u8, and adding a test to assert that.

(cherry picked from commit 57057f8d39)

# Conflicts:
#	core/src/retransmit_stage.rs
#	gossip/src/cluster_info.rs
#	ledger/Cargo.toml
#	ledger/src/blockstore.rs
#	ledger/src/shred.rs

* changes Blockstore::is_shred_duplicate arg type to ShredType

(cherry picked from commit 48dfdfb4d5)

# Conflicts:
#	ledger/src/blockstore.rs

* removes backport merge conflicts

Co-authored-by: behzad nouri <behzadnouri@gmail.com>
2021-12-31 16:47:45 +00:00
ec970f9d69 checks for authorized voter early on in the vote-listener pipeline (backport #22169) (#22188)
* checks for authorized voter early on in the vote-listener pipeline (#22169)

Before votes are verified that they are signed by the authorized voter,
they might be dropped in verified-vote-packets code. If there are
enough many spam votes from unauthorized voters, this may potentially
drop valid votes but keep the false ones.
https://github.com/solana-labs/solana/blob/57986f982/core/src/verified_vote_packets.rs#L165-L168

(cherry picked from commit c0c6038654)

# Conflicts:
#	core/src/cluster_info_vote_listener.rs

* removes backport merge conflicts

Co-authored-by: behzad nouri <behzadnouri@gmail.com>
2021-12-30 17:52:36 +00:00
7793a11b65 Bump solana_rbpf to version v0.2.20 (#22166) 2021-12-30 17:34:11 +01:00