Solayer 백서

Solayer

원문

bitpro가 원문에서 글자만 모은 내용이에요. 표·그림·수식은 빠지거나 깨질 수 있어요. 전체 2쪽 중 2쪽

es and their corresponding memory ad- dresses, data length, and version number (i.e., how many times the account has been written). Second, a contiguous data region stores the actual account state data along with associated syn- chronization primitives and metadata. We observe that most state change on Solana do not modify the length of data in the account. Under rare occurence of state size change, the account data may not be stored in contiguous memory, and later gets redistributed to the contiguous memory during routine rebalancing. Third, an in-memory local cache maintains frequently accessed account data using an LRU (Least Recently Used) eviction policy to reduce network round-trips for popular accounts. To enable efficient cross-node data access by the executor, SOLAYER CHAIN leverages Infini- Band RDMA (Remote Direct Memory Access) protocol. This approach offers several advantages: ultra-low latency (ns-level) data access across nodes, bypass of operating system overhead, reduced CPU utilization during data transfer, and zero-copy data movement between nodes. The RDMA infrastructure allows SOLAYER CHAIN to maintain high performance even when data needs to be fetched from remote nodes, ensuring consistent transaction processing speeds across the distributed system. The system implements dynamic load balancing through a background rebalancing mechanism that operates during periods of low network activity. This process monitors account access pat- terns, analyzes historical memory access footprints, and redistributes data across nodes to optimize locality and minimize cross-node data fetches for common transaction patterns. The rebalanc- ing process considers multiple factors, including access frequency of accounts, data size, network topology, node capacity constraints, and current load distribution. This adaptive approach ensures 8 that frequently co-accessed data resides on the same node, reducing the need for remote data access and improving overall transaction throughput. 4 Scaling Consensus Existing rollup-based designs typically offload verification to a large set of commodity validators that must reconstruct or dispute transactions posted on Layer 1 (L1). However, verifying trans- action streams at 1Gb/s is beyond the capacity of most commodity nodes. Moreover, posting 1Gb worth of data on any data availability (DA) layer or L1 is prohibitively expensive, saturating available bandwidth and raising on-chain fees. Consequently, we introduce a Proof-of-Authority- and-Stake (not to be confused with Proof of Stake and Authority or PoSA) architecture: a trusted entity acts as a sequencer (leader) and publishes shreds (a set of transactions in the block), and ev- ery prover stakes and votes to decide whether a shred can be accepted. Solana is used as a fallback consensus venue when the sequencer is behaving maliciously. Our protocol batches transactions into shreds, each containing a slot number, a vector of trans- actions, version metadata for accessed accounts, and linkage hashes (e.g., last shred version). The presence of account versions is critical because it allows each shred to indicate the exact state con- text in which the sequencer executed the transactions. By referencing these state versions, any node that receives the shred can re-construct the relevant portion of the ledger and compute the resulting “effect hash”—the cryptographic digest of post-transaction states. Only a minimal (Effect Hash, Shred Hash) pair is published on Solana to ensure data availability, while most of the bulk data is propagated to each prover. This design caps on-chain overhead and avoids saturating L1 capacity. Upon receiving a shred, a prover checks if its local ledger contains the correct account version. If not, it requests the missing shreds necessary to build up the needed state from the leader. Then, the prover re-executes all transactions in the shred, deriving the effect hash. If the locally computed hash matches the shred’s embedded effect hash, the prover votes for acceptance on S OLAYER CHAIN . Once a shred accumulates votes from 51% of the selected provers, the sequencer assembles a proof for the shred and marks the shred as finalized if all previous shreds are finalized. Should the sequencer propose invalid or malicious shreds, honest provers will detect discrep- ancies between the expected and computed effect hashes and vote against them. It is impossible to include invalid transactions in the sequencer itself. Repeated offenses mark the sequencer as offline, triggering a failover to a backup sequencer from a proof-of-authority set. The re-election occurs on Solana as a down sequencer, which means S OLAYER CHAIN can no longer process transactions. All honest provers vote for the re-election and advance to the next sequencer once the vote reaches 2/3. If 2/3 of the provers are not malicious, re-election can finish in seconds. Furthermore, to curb dishonest or lazy provers, the sequencer periodically broadcasts intentionally invalid shreds: any prover that “blindly” votes for such a shred is automatically slashed and excluded from further rounds. This mechanism deters passive acceptance of shreds and ensures each prover consistently re-executes transactions. To combat censorship resistance, if the sequencer repeatedly ignores a transaction (e.g., censorship), any user can insert the ignored transaction into a future shred by 9 sending the transaction data on Solana to the relevant program; the sequencer’s refusal to accept a transaction on Solana similarly flags it as unresponsive or malicious. As it is unrealistic for provers to use costly HPC infrastructure and hardware accelerators to follow the chain and verify every shred, the sequencer leverages the round-robin method to ran- domly select only 2/3 of the online prover set to execute the shred. The provers further subdivide the task to different nodes they possess in a round-robin method. If a prover has 10 nodes, each node only needs to handle 1/15 of all shreds. Provers can use the cloud to scale the nodes to handle more traffic elastically. Note that to achieve a 51% vote, only 4/5 of the provers selected have to vote for the shred, allowing downtime of provers. Under edge cases, when more than 1/5 of the provers selected are down, the sequencer should select more provers to join the verification of the shred. Failure to do so would make the sequencer marked as down. The sequencer has no incentive to conduct denial of service (e.g., always selecting the same provers to verify all shreds) for the provers because if the sequencer can no longer finalize blocks, it is marked as down. Provers receive fees from processed shreds and inflationary $LAYER rewards as incentives to participate. However, if they exhibit malicious behavior or repeatedly fail to process shreds, they face tiered slashing penalties and get evicted from the prover set until manual re-joining. The first violation results in the loss of that epoch’s accrued fees. A second violation in that epoch incurs a 1% slash on staked tokens, and each subsequent violation within that epoch leads to a 5% stake slash. 5 Improving User Experience 5.1 Wallet-agnostic and DApp-first integration Traditional chain integrations require support at both the wallet and dApp layers. For EVM L2s, this is because EIP-155 mandates that the chain ID be included in the signature payload, which wal- lets enforce. However, SVM transaction signatures do not include chain IDs within the transaction structure. Instead, each transaction contains a recent block hash, and replaying the transaction on other chains simply results in its rejection. Secondly, in EVM ecosystems, wallets are responsible for transaction broadcasting, whereas in SVM, the dApp is responsible for broadcasting transac- tions. Using S OLAYER CHAIN ’s SDK, dApps can allow users to create transactions directly on SOLAYER CHAIN using any Solana-compatible wallet without requiring explicit wallet support. While direct wallet support remains desirable for assets to be displayed seamlessly, it is not a strict requirement for transaction execution and user onboarding. 5.2 Hooks In many on-chain environments, re-executing transactions to detect post-execution opportunities — such as arbitrage, liquidations, or real-time account indexing—can be computationally expen- sive for off-chain entities. To address this, we introduce Hooks: a mechanism that automatically 10 executes user-defined logic immediately after a transaction interacts with one or more on-chain pro- grams. Conceptually, Hooks serve as a built-in “backrunning” layer: once a targeted program has updated its state, one or more Hooks can trigger arbitrage checks, liquidation actions, accounting operations, or any other use case requiring timely state awareness. Technically, a Hook has the same definition as a transaction: Hook users provide accounts and data, and gas is charged from the designated account each time the hook is triggered. The hook can be disabled after three occurrences of lack of funds to pay gas in the fee payer account. S OLAYER CHAIN provides a precompile that manages Hook registration and bidding. Users submit bids to attach their Hooks to specific programs, competing in a Dutch-auction-like model where the top 16 bids (per program) are eligible for execution during the following epoch. If a transaction touches multiple programs with registered Hooks, only 16 total Hooks (sorted by descending bid) will run. Once the system completes the transaction, these Hooks are called in sequence, and the bid for each Hook is split: 40% to the transaction initiator, 40% to the owner of the program, and 20% to the network. This incentive model reduces the cost of exhaustive replay while encouraging ecosystem par- ticipants to incorporate Hooks. The 40-40-20 distribution ensures that both end-users and program owners benefit from higher bids while the network collects a portion to offset additional on-chain overhead. By embedding Hooks directly into the execution pipeline, S OLAYER CHAIN also mit- igates spam or off-chain MEV exploitation, as real-time logic becomes accessible to any party willing to bid. Overall, Hooks provides a fair and performance-oriented approach to automating post-transaction actions without overburdening the core network. 5.3 Cross-chain Contract Calls SOLAYER CHAIN has a bi-directional native bridge implemented inside the sequencer to relay messages and assets from Solana to S OLAYER CHAIN . The bridge ignores Solana re-org by im- plementing an insurance fund that automatically covers loss due to re-org. If the total value of the asset (measured through an oracle) relayed before the finalization is lower than the insurance fund size, the asset becomes immediately available on SOLAYER CHAIN . Otherwise, the asset be- comes available after the transaction is finalized. All messages can be relayed instantly (ignoring re-org) or after finalization by setting the flag in the transaction. The receiver hook is automatically invoked once the message becomes available and can call additional programs. SOLAYER CHAIN also introduces a cross-chain program call bridge through account mirroring, where each SOLAYER CHAIN program and account has a corresponding Program Derived Address (PDA) on the Solana mainnet. Central to this design is the MainnetCall instruction type, enabling atomic cross-chain operations orchestrated via a built-in system program. Whenever a S OLAYER CHAIN program invokes MainnetCall, the transaction routes instructions to its associated PDA on Solana. In doing so, programs can transfer funds, dispatch cross-chain function calls, and even execute complex on-chain logic spanning both networks, all within a single atomic operation. To ensure atomicity, MainnetCall instruction never reverts (even when the Solana transaction is reverted) and can be inserted only at the end of the transaction but not in between so that when 11 Solana re-org occurs, there is no impact, as the Solana transaction only needs to be broadcasted again until it is finalized. By combining both bridge, one can implement solutions including but not limited to single transaction cross-chain swap and cross-chain yield vault rebalancing. 5.4 Jumbo Transaction To support complex transaction logic, especially for hook transactions, S OLAYER CHAIN intro- duces jumbo transactions. This new transaction type significantly increases the transaction size limit, allowing for more cross-program invocations. Fees for jumbo transactions grow exponen- tially as the transaction size increases. By leveraging jumbo transactions, users can read and write thousands of accounts, execute thousands of instructions, or deploy multiple programs within a single transaction. 5.5 ZK-Login Users can use their Google, X, Reddit, or any service that support OAuth as a wallet. S OLAYER CHAIN has native support for transactions signed using OAuth. The underlying workflow is similar to Sui’s zkLogin. 12
프로젝트로 돌아가기