Skip to content

firedancer: return correct CUs for stop_use_static_simple_vote_tx_cost#15

Open
topointon-jump wants to merge 30 commits intov4.0.0-beta.2-fdfrom
v4.0.0-alpha.0-fd2a-simple-vote-patch
Open

firedancer: return correct CUs for stop_use_static_simple_vote_tx_cost#15
topointon-jump wants to merge 30 commits intov4.0.0-beta.2-fdfrom
v4.0.0-alpha.0-fd2a-simple-vote-patch

Conversation

@topointon-jump
Copy link
Copy Markdown

No description provided.

AshwinSekar and others added 10 commits March 10, 2026 08:56
The libbz2-sys crate will attempt to discover a system libbz2 via
pkg-config.  If found, libbz2 will not be compiled as part of the cargo
build process.

However, Firedancer's build system will never link bz2 regardless of
what cargo build does.

This will cause link errors regarding missing libbz2 symbols depending
on the system's pkg-config.

Cargo's bizarre feature system does not allow the user to directly
control the way libbz2 is linked.  Instead, every crate dependent on
libbz2 will have to plumb down the static feature down to libbz2. (e.g.
rocksdb => librocksdb-sys => bzip2-sys)

In another bizarre twist, the rocksdb crate even with default features
disabled, will add libz and libbz2 crates, without the static features.
Thus, we add back the bzip2 feature to RocksDB, which somehow fixes
this behavior.
We want to link the validator and genesis binaries into our Firedancer
binary for zero configuration and easy deployment. We also don't want
to rename the main.rs files, since that would cause repeated merge
conflicts and make it hard to tell what Firedancer has changed. To do
this, we point lib.rs at main.rs (main is a module), and then don't try
build the binary.
Firedancer determines the port for the TVU, which is specified in its
config file, so an argument is added to the CLI and plumbed all the
way through to gossip to wire this up.
The Firedancer shredder needs to know which nodes in the cluster
to forward shreds to, which information is currently maintained
by the Solana Labs cluster info. For now, we communicate this
across the IPC boundary.
It's important for the Firedancer pack code to see all available
transactions for packing, so it can schedule them optimally and
avoid conflicts.  Previously we have rerouted all transactions
except gossiped votes which came via. a different path. This
change also reroutes those so everything goes to Firedancer.  We route
gossiped votes to the dedup tile so that if the same vote comes in over
the normal TPU port, it's correctly identified as a duplicate.

Co-authored-by: Yufeng Zhou <yufzhou@jumptrading.com>
The leader schedule cache is updated so that it has an optional path to
send stake weights to firedancer.  This is done on a mcache because we
do not want to drop or miss any recomputations, otherwise Firedancer
will not recover.  The pack tile uses stake weights to compute the
leader schedule, and the shred tile uses stake weights to compute shred
destinations.
The shred version sometimes needs to be fetched via. gossip
on startup, which Firedancer can't do so we communicate it
to Firedancer here via shared memory.
@alpeng-jump alpeng-jump force-pushed the v4.0.0-alpha.0-fd2a branch from a87af37 to 6ea8eac Compare March 11, 2026 08:09
@topointon-jump topointon-jump force-pushed the v4.0.0-alpha.0-fd2a-simple-vote-patch branch from 470a265 to 4fb7b58 Compare March 11, 2026 20:03
@topointon-jump topointon-jump changed the base branch from v4.0.0-alpha.0-fd2a to v4.0.0-beta.2-fd March 17, 2026 16:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants