Skip to content

Commit

Permalink
remove solana-sdk from compute-budget-bench (#4057)
Browse files Browse the repository at this point in the history
  • Loading branch information
kevinheavey authored Dec 11, 2024
1 parent 7e9c495 commit 5627bbb
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 10 deletions.
5 changes: 4 additions & 1 deletion Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 4 additions & 1 deletion programs/compute-budget-bench/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,11 @@ edition = { workspace = true }
criterion = { workspace = true }
solana-compute-budget = { workspace = true }
solana-compute-budget-instruction = { workspace = true }
solana-compute-budget-interface = { workspace = true }
solana-compute-budget-program = { workspace = true }
solana-sdk = { workspace = true }
solana-feature-set = { workspace = true }
solana-message = { workspace = true }
solana-sdk-ids = { workspace = true }
solana-svm-transaction = { workspace = true }

[[bench]]
Expand Down
15 changes: 7 additions & 8 deletions programs/compute-budget-bench/benches/compute_budget.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,9 @@ use {
criterion::{black_box, criterion_group, criterion_main, Criterion},
solana_compute_budget::compute_budget_limits::ComputeBudgetLimits,
solana_compute_budget_instruction::instructions_processor::process_compute_budget_instructions,
solana_sdk::{
compute_budget::ComputeBudgetInstruction, feature_set::FeatureSet,
instruction::CompiledInstruction,
},
solana_compute_budget_interface::ComputeBudgetInstruction,
solana_feature_set::FeatureSet,
solana_message::compiled_instruction::CompiledInstruction,
solana_svm_transaction::instruction::SVMInstruction,
std::num::NonZero,
};
Expand All @@ -15,7 +14,7 @@ const SIXTY_FOUR_MB: u32 = 64 * 1024 * 1024;

fn bench_request_heap_frame(c: &mut Criterion) {
let instruction = [(
solana_sdk::compute_budget::id(),
solana_sdk_ids::compute_budget::id(),
CompiledInstruction::new_from_raw_parts(
0,
ComputeBudgetInstruction::request_heap_frame(ONE_PAGE).data,
Expand Down Expand Up @@ -48,7 +47,7 @@ fn bench_request_heap_frame(c: &mut Criterion) {

fn bench_set_compute_unit_limit(c: &mut Criterion) {
let instruction = [(
solana_sdk::compute_budget::id(),
solana_sdk_ids::compute_budget::id(),
CompiledInstruction::new_from_raw_parts(
0,
ComputeBudgetInstruction::set_compute_unit_limit(1024).data,
Expand Down Expand Up @@ -81,7 +80,7 @@ fn bench_set_compute_unit_limit(c: &mut Criterion) {

fn bench_set_compute_unit_price(c: &mut Criterion) {
let instruction = [(
solana_sdk::compute_budget::id(),
solana_sdk_ids::compute_budget::id(),
CompiledInstruction::new_from_raw_parts(
0,
ComputeBudgetInstruction::set_compute_unit_price(1).data,
Expand Down Expand Up @@ -114,7 +113,7 @@ fn bench_set_compute_unit_price(c: &mut Criterion) {

fn bench_set_loaded_accounts_data_size_limit(c: &mut Criterion) {
let instruction = [(
solana_sdk::compute_budget::id(),
solana_sdk_ids::compute_budget::id(),
CompiledInstruction::new_from_raw_parts(
0,
ComputeBudgetInstruction::set_loaded_accounts_data_size_limit(1).data,
Expand Down

0 comments on commit 5627bbb

Please sign in to comment.