Skip to content
Open
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
2 changes: 0 additions & 2 deletions basic_bootloader/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -57,8 +57,6 @@ fusaka-blobs = ["zk_ee/fusaka-blobs"]
fusaka = ["pectra", "eip-7825", "eip-7934", "eip-7918", "zk_ee/eip-7825", "basic_system/fusaka"]
burn_base_fee = []
cycle_marker = ["system_hooks/cycle_marker", "cycle_marker/log_to_file"]
resources_for_tester = []
unlimited_native = []
disable_system_contracts = []
error_origins = ["zk_ee/error_origins"]
delegation = ["zk_ee/delegation", "evm_interpreter/delegation", "system_hooks/delegation", "basic_system/delegation"]
Expand Down
11 changes: 3 additions & 8 deletions basic_bootloader/src/bootloader/block_flow/zk/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -65,24 +65,19 @@ where
"Block blob gas limit reached, invalidating transaction\n"
);
Err(InvalidTransaction::BlockBlobGasLimitReached)
} else if !cfg!(feature = "resources_for_tester")
&& computational_native_used > MAX_NATIVE_COMPUTATIONAL
{
// ZKsync OS-specific resources are not checked for evm tester
} else if computational_native_used > MAX_NATIVE_COMPUTATIONAL {
system_log!(
system,
"Block native limit reached, invalidating transaction\n"
);
Err(InvalidTransaction::BlockNativeLimitReached)
} else if !cfg!(feature = "resources_for_tester") && pubdata_used > system.get_pubdata_limit() {
// ZKsync OS-specific resources are not checked for evm tester
} else if pubdata_used > system.get_pubdata_limit() {
system_log!(
system,
"Block pubdata limit reached, invalidating transaction\n"
);
Err(InvalidTransaction::BlockPubdataLimitReached)
} else if !cfg!(feature = "resources_for_tester") && logs_used > MAX_NUMBER_OF_LOGS {
// ZKsync OS-specific resources are not checked for evm tester
} else if logs_used > MAX_NUMBER_OF_LOGS {
system_log!(
system,
"Block logs limit reached, invalidating transaction\n"
Expand Down
5 changes: 0 additions & 5 deletions basic_bootloader/src/bootloader/constants.rs
Original file line number Diff line number Diff line change
Expand Up @@ -72,11 +72,6 @@ pub const CALLDATA_TOKEN_GAS_COST: u64 = 4;
/// EIP-7623 minimal "token" cost
pub const TOTAL_COST_FLOOR_PER_TOKEN: u64 = 10;

/// EVM tester requires a high native_per_gas, but it hard-codes
/// low gas prices. We need to bypass the usual way to compute this
/// value. The value is so high because of modexp tests.
pub const TESTER_NATIVE_PER_GAS: u64 = 25_000;

// Default native price for L1->L2 transactions.
// TODO (EVM-1157): find a reasonable value for it.
pub const L1_TX_NATIVE_PRICE: U256 = U256::from_limbs([10, 0, 0, 0]);
Expand Down
2 changes: 0 additions & 2 deletions basic_bootloader/src/bootloader/errors.rs
Original file line number Diff line number Diff line change
Expand Up @@ -71,8 +71,6 @@ pub enum InvalidTransaction {
AccessListNotSupported,
/// Unacceptable pubdata price.
PubdataPriceTooHigh,
/// Block gas limit is too high.
BlockGasLimitTooHigh,
/// Protocol upgrade tx should be first in the block.
UpgradeTxNotFirst,
/// Bootloader received insufficient fees
Expand Down
1 change: 0 additions & 1 deletion basic_bootloader/src/bootloader/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,6 @@ where
S::Allocator::default(),
)?;

// we will model initial calldata buffer as just another "heap"
let mut system: System<S> = System::init_from_metadata_and_oracle(metadata, oracle)?;
let mut system_functions = HooksStorage::new_in(system.get_allocator());

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,8 @@ pub struct RlpEncodedTransaction<A: Allocator> {
// time.
tx_hash: Option<Bytes32>,
// Note: this field is not the recovered signer, but rather an address
// passed by oracle. Needs to be checked to be equal to recovered address.
// passed by oracle. Needs to be checked to be equal to recovered address
// in untrusted environments, e.g. proving mode
from: B160,
}

Expand Down
Loading
Loading