Skip to content

Commit

Permalink
Cairo v0.13.0.
Browse files Browse the repository at this point in the history
  • Loading branch information
liorgold2 committed Dec 12, 2023
1 parent 92fb7df commit caba294
Show file tree
Hide file tree
Showing 8 changed files with 17 additions and 16 deletions.
2 changes: 1 addition & 1 deletion WORKSPACE
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ http_archive(
"//src/starkware/starknet/compiler/v1:BUILD." + CAIRO_COMPILER_ARCHIVE,
),
strip_prefix = "cairo",
url = "https://github.com/starkware-libs/cairo/releases/download/v2.4.0-rc6/release-x86_64-unknown-linux-musl.tar.gz",
url = "https://github.com/starkware-libs/cairo/releases/download/v2.4.0/release-x86_64-unknown-linux-musl.tar.gz",
)

http_archive(
Expand Down
2 changes: 1 addition & 1 deletion src/starkware/cairo/lang/VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
0.13.0a3
0.13.0
3 changes: 2 additions & 1 deletion src/starkware/cairo/sharp/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -49,9 +49,10 @@ py_library(
],
visibility = ["//visibility:public"],
deps = [
"fact_checker_lib",
":fact_checker_lib",
"//src/starkware/cairo/bootloaders:cairo_bootloader_generate_fact_lib",
"//src/starkware/cairo/bootloaders:cairo_hash_program_lib",
"//src/starkware/cairo/lang/compiler:cairo_compile_lib",
"//src/starkware/cairo/lang/vm:cairo_vm_crypto_lib",
"//src/starkware/cairo/lang/vm:cairo_vm_lib",
requirement("urllib3"),
Expand Down
2 changes: 1 addition & 1 deletion src/starkware/cairo/sharp/config.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"prover_url": "https://testnet.provingservice.io",
"verifier_address": "0x8f97970aC5a9aa8D130d35146F5b59c4aef57963",
"verifier_address": "0x07ec0D28e50322Eb0C159B9090ecF3aeA8346DFe",
"steps_limit": 1000000
}
4 changes: 2 additions & 2 deletions src/starkware/cairo/sharp/sharp_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -221,7 +221,7 @@ def submit(args, command_args):


def get_job_status(args, command_args):
parser = argparse.ArgumentParser(description="Retreive the status of a SHARP Cairo job.")
parser = argparse.ArgumentParser(description="Retrieve the status of a SHARP Cairo job.")
parser.add_argument("job_key", type=str, help="The key identifying the job.")

parser.parse_args(command_args, namespace=args)
Expand All @@ -242,7 +242,7 @@ def is_verified(args, command_args):
)
parser.add_argument("fact", type=str, help="The fact to verify if registered.")
parser.add_argument(
"--node_url", required=True, type=str, help="URL for a Goerli Ethereum node RPC API."
"--node_url", required=True, type=str, help="URL for a Sepolia Ethereum node RPC API."
)

parser.parse_args(command_args, namespace=args)
Expand Down
2 changes: 1 addition & 1 deletion src/starkware/starknet/definitions/constants.py
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@
CONSUMED_MSG_TO_L2_ENCODED_DATA_SIZE = (L1_TO_L2_MSG_HEADER_SIZE + 1) - CONSUMED_MSG_TO_L2_N_TOPICS

# The (empirical) L1 gas cost of each Cairo step.
N_STEPS_FEE_WEIGHT = 0.01
N_STEPS_FEE_WEIGHT = 0.005

# Expected return values of a 'validate' entry point.
VALIDATE_RETDATA = [from_bytes(b"VALID")]
Expand Down
16 changes: 8 additions & 8 deletions src/starkware/starknet/definitions/general_config.py
Original file line number Diff line number Diff line change
Expand Up @@ -75,15 +75,15 @@
# Given in units of wei.
DEFAULT_DEPRECATED_L1_GAS_PRICE = 10**11
DEFAULT_CAIRO_RESOURCE_FEE_WEIGHTS = {
N_STEPS_RESOURCE: 0.01,
N_STEPS_RESOURCE: 0.005,
**{builtin: 0.0 for builtin in ALL_BUILTINS.with_suffix()},
with_suffix(PEDERSEN_BUILTIN): 0.32,
with_suffix(RANGE_CHECK_BUILTIN): 0.16,
with_suffix(ECDSA_BUILTIN): 20.48,
with_suffix(KECCAK_BUILTIN): 20.48,
with_suffix(BITWISE_BUILTIN): 0.64,
with_suffix(EC_OP_BUILTIN): 10.24,
with_suffix(POSEIDON_BUILTIN): 0.32,
with_suffix(PEDERSEN_BUILTIN): 0.16,
with_suffix(RANGE_CHECK_BUILTIN): 0.08,
with_suffix(ECDSA_BUILTIN): 10.24,
with_suffix(KECCAK_BUILTIN): 10.24,
with_suffix(BITWISE_BUILTIN): 0.32,
with_suffix(EC_OP_BUILTIN): 5.12,
with_suffix(POSEIDON_BUILTIN): 0.16,
}

DEFAULT_ETH_IN_STRK_WEI = 10**21
Expand Down
2 changes: 1 addition & 1 deletion src/starkware/starknet/definitions/general_config.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
cairo_resource_fee_weights:
n_steps: 0.01
n_steps: 0.005
compiled_class_hash_commitment_tree_height: 251
constant_gas_price: false
contract_storage_commitment_tree_height: 251
Expand Down

0 comments on commit caba294

Please sign in to comment.