You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Developer Goal: Ensure the contract stays within Soroban's strict CPU and memory limits, especially during the iteration over many outcomes or bettors.
Detailed Tasks:
Iteration Audit: Review resolve_market and any potential loop that iterates over a Vec.
Asymptotic Logic: If a market has thousands of winners, switch from "Push" payouts (one transaction) to "Pull" payouts (each user claims their own - see Issue Advanced Payout & Reward Distribution system #1).
Storage Costs: Optimize the Market struct using Option<u32> instead of large default integers where possible to save on ledger footprint costs.
Verification Checklist:
Script with soroban contract invoke that measures instructions for a 100-outcome market.
git checkout -b features/issue-7-Automated Gas Benchmarking & Instruction Optimization
Descriptions:
Issue #7:
Developer Goal: Ensure the contract stays within Soroban's strict CPU and memory limits, especially during the iteration over many outcomes or bettors.
Detailed Tasks:
resolve_marketand any potential loop that iterates over aVec.Marketstruct usingOption<u32>instead of large default integers where possible to save on ledger footprint costs.Verification Checklist:
soroban contract invokethat measuresinstructionsfor a 100-outcome market.git checkout -b features/issue-7-Automated Gas Benchmarking & Instruction Optimizationdevelopbranch