Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

rusk: Fix AST benchmarks #1959

Merged
merged 3 commits into from
Jul 11, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
50 changes: 41 additions & 9 deletions rusk/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ INITFILE?=../rusk-recovery/config/localnet.toml
help: ## Display this help screen
@grep -h -E '^[a-zA-Z_-]+:.*?## .*$$' $(MAKEFILE_LIST) | awk 'BEGIN {FS = ":.*?## "}; {printf "\033[36m%-15s\033[0m %s\n", $$1, $$2}'

test: ## Run Rusk tests
test: build-bench ## Run Rusk tests
@cargo test \
--release \
--features testwallet \
Expand All @@ -12,23 +12,55 @@ test: ## Run Rusk tests
clippy: ## Run clippy
@cargo clippy --all-features --release -- -D warnings
@cargo clippy --no-default-features --release -- -D warnings
@cargo clippy --no-default-features --features ephemeral --release -- -D warnings
@cargo clippy --no-default-features --features recovery-keys --release -- -D warnings
@cargo clippy --no-default-features --features recovery-state --release -- -D warnings
@cargo clippy --no-default-features --features prover --release -- -D warnings
@cargo clippy --no-default-features --features node --release -- -D warnings
@cargo clippy \
--no-default-features \
--features ephemeral \
--release \
-- -D warnings
@cargo clippy \
--no-default-features \
--features recovery-keys \
--release \
-- -D warnings
@cargo clippy \
--no-default-features \
--features recovery-state \
--release \
-- -D warnings
@cargo clippy \
--no-default-features \
--features prover \
--release \
-- -D warnings
@cargo clippy \
--no-default-features \
--features node \
--release \
-- -D warnings
@cargo check --benches --features testwallet

build: ## Build rusk binary
@cargo build --release

build-bench: ## Build the benchmarks
@cargo bench --features testwallet --no-run

run:
@cargo r --release --bin rusk

recovery-keys: ## Build circuit keys
@cargo r --no-default-features --features recovery-keys --release -- recovery-keys
@cargo r \
--no-default-features \
--features recovery-keys \
--release \
-- recovery-keys

recovery-state: ## Build network state
@cargo r --no-default-features --features recovery-state --release -- recovery-state --init $(INITFILE)
@cargo r \
--no-default-features \
--features recovery-state \
--release \
-- recovery-state \
--init $(INITFILE)

.PHONY: test help clippy build recovery-keys recovery-state rusk
.PHONY: test help clippy build build-bench recovery-keys recovery-state rusk
100 changes: 0 additions & 100 deletions rusk/benches/block

This file was deleted.

4 changes: 3 additions & 1 deletion rusk/benches/block_ingestion.rs
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,9 @@ use tempfile::tempdir;
use common::state::new_state;

fn load_txs() -> Vec<Transaction> {
const TXS_BYTES: &[u8] = include_bytes!("block");
// The file "txs" can be generated using `generate_phoenix_txs()` in
// "tests/rusk-state.rs".
const TXS_BYTES: &[u8] = include_bytes!("txs");

let mut txs = Vec::new();

Expand Down
Loading
Loading