Skip to content
forked from diem/diem

Diem’s mission is to build a trusted and innovative financial network that empowers people and businesses around the world.

License

Notifications You must be signed in to change notification settings

danielxiangzl/Block-STM

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Block-STM

This repository implements and benchmarks Block-STM and other baselines for the paper Block-STM: Scaling Blockchain Execution by Turning Ordering Curse to a Performance Blessing. The implementation of Block-STM has been merged on the main branch of the Diem blockchain open source code-base, see PR.

Branches block_stm and aptos implement and benchmark Block-STM with Diem peer-to-peer transactions and Aptos peer-to-peer transactions, respectively. The 160k tps number is achievable for Aptos peer-to-peer transactions. Similarly, branches bohm and litm implement and benchmark Bohm and LiTM with Diem peer-to-peer transactions, respectively. After running Block-STM, you can checkout to these branches and run them following similar steps as below.

Run Block-STM:

  1. ./scripts/dev_setup.sh
  2. curl https://sh.rustup.rs -sSf | sh
  3. Restart the shell if necessary
  4. cd diem-move/diem-transaction-benchmarks/src
  5. cargo run --release main

Use taskset commands to run experiments with different threads number.

If you run the benchmark on Ubuntu, please use Ubuntu 20.04.

If you run the benchmark on M1, there may be error error: failed to run custom build command for librocksdb-sys v6.20.3. This solution should resolve the issue by downgrading to clang 14.

Set parameters (number of accounts/transactions/warmup-runs/runs) in diem-move/diem-transaction-benchmarks/src/main.rs.

let acts = [2, 10, 100, 1000, 10000];
let txns = [1000, 10000];
let num_warmups = 2;
let num_runs = 10;

Run sequential baseline:

  1. ./scripts/dev_setup.sh
  2. cd diem-move/diem-transaction-benchmarks/benches
  3. cargo bench peer_to_peer

Set parameters (number of accounts/transactions) in diem-move/diem-transaction-benchmarks/src/transactions.rs.

/// The number of accounts created by default.
pub const DEFAULT_NUM_ACCOUNTS: usize = 100;

/// The number of transactions created by default.
pub const DEFAULT_NUM_TRANSACTIONS: usize = 1000;

Note to readers: On December 1, 2020, the Libra Association was renamed to Diem Association. The project repos are in the process of being migrated. All projects will remain available for use here until the migration to a new GitHub Organization is complete.

Diem Logo

Diem Rust Crate Documentation (main) License grcov test history Automated Issues Discord chat

Diem Core implements a decentralized, programmable database which provides a financial infrastructure that can empower billions of people.

Note to Developers

  • Diem Core is a prototype.
  • The APIs are constantly evolving and designed to demonstrate types of functionality. Expect substantial changes before the release.
  • We’ve launched a testnet that is a live demonstration of an early prototype of the Diem Blockchain software.

Contributing

To begin contributing, sign the CLA. You can learn more about contributing to the Diem project by reading our Contribution Guide and by viewing our Code of Conduct.

Getting Started

Learn About Diem

Try Diem Core

Technical Papers

Blog

Community

License

Diem Core is licensed as Apache 2.0.

About

Diem’s mission is to build a trusted and innovative financial network that empowers people and businesses around the world.

Resources

License

Code of conduct

Security policy

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Rust 94.3%
  • JavaScript 2.9%
  • HCL 0.9%
  • CSS 0.7%
  • Shell 0.6%
  • TypeScript 0.3%
  • Other 0.3%