Skip to content

Commit

Permalink
Some more stuff, like autocompletion and readme enhancements
Browse files Browse the repository at this point in the history
  • Loading branch information
EmilLuta committed Nov 15, 2024
1 parent 47536aa commit cdaeee0
Show file tree
Hide file tree
Showing 4 changed files with 29 additions and 7 deletions.
5 changes: 3 additions & 2 deletions prover/crates/lib/prover_job_processor/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -133,10 +133,11 @@ prover implementation)

### 3. Optimize prover components for speed and multi-datacenter/multi-cloud setups

Previously, provers were running "sync". Load job, once loaded, execute it, once executed, save it's result. Whilst this
Previously, provers were running "sync". Load job, once loaded, execute it, once executed, save its result. Whilst this
is fine, all steps can be done in parallel. This becomes super important when database and running machine are far away
and the round trip to database can cause up to 50% of the entire time. In a multi-cloud (read as future) setup, this
becomes even more painful.
becomes even more painful. For free, we remove the current bottleneck from database (which was previous bottleneck,
due to # of connections).

### 4. Increase speed of delivery of prover components

Expand Down
6 changes: 5 additions & 1 deletion zkstack_cli/crates/zkstack/completion/_zkstack.zsh
Original file line number Diff line number Diff line change
Expand Up @@ -1922,7 +1922,11 @@ _arguments "${_arguments_options[@]}" : \
'--round=[]:ROUND:(all-rounds basic-circuits leaf-aggregation node-aggregation recursion-tip scheduler)' \
'--threads=[]:THREADS:_default' \
'--max-allocation=[Memory allocation limit in bytes (for prover component)]:MAX_ALLOCATION:_default' \
'--witness-vector-generator-count=[]:WITNESS_VECTOR_GENERATOR_COUNT:_default' \
'-l+[]:LIGHT_WVG_COUNT:_default' \
'--light-wvg-count=[]:LIGHT_WVG_COUNT:_default' \
'-h+[]:HEAVY_WVG_COUNT:_default' \
'--heavy-wvg-count=[]:HEAVY_WVG_COUNT:_default' \
'-m+[]:MAX_ALLOCATION:_default' \
'--max-allocation=[]:MAX_ALLOCATION:_default' \
'--docker=[]:DOCKER:(true false)' \
'--tag=[]:TAG:_default' \
Expand Down
5 changes: 3 additions & 2 deletions zkstack_cli/crates/zkstack/completion/zkstack.fish
Original file line number Diff line number Diff line change
Expand Up @@ -500,8 +500,9 @@ complete -c zkstack -n "__fish_zkstack_using_subcommand prover; and __fish_seen_
complete -c zkstack -n "__fish_zkstack_using_subcommand prover; and __fish_seen_subcommand_from run" -l round -r -f -a "{all-rounds\t'',basic-circuits\t'',leaf-aggregation\t'',node-aggregation\t'',recursion-tip\t'',scheduler\t''}"
complete -c zkstack -n "__fish_zkstack_using_subcommand prover; and __fish_seen_subcommand_from run" -l threads -r
complete -c zkstack -n "__fish_zkstack_using_subcommand prover; and __fish_seen_subcommand_from run" -l max-allocation -d 'Memory allocation limit in bytes (for prover component)' -r
complete -c zkstack -n "__fish_zkstack_using_subcommand prover; and __fish_seen_subcommand_from run" -l witness-vector-generator-count -r
complete -c zkstack -n "__fish_zkstack_using_subcommand prover; and __fish_seen_subcommand_from run" -l max-allocation -r
complete -c zkstack -n "__fish_zkstack_using_subcommand prover; and __fish_seen_subcommand_from run" -s l -l light-wvg-count -r
complete -c zkstack -n "__fish_zkstack_using_subcommand prover; and __fish_seen_subcommand_from run" -s h -l heavy-wvg-count -r
complete -c zkstack -n "__fish_zkstack_using_subcommand prover; and __fish_seen_subcommand_from run" -s m -l max-allocation -r
complete -c zkstack -n "__fish_zkstack_using_subcommand prover; and __fish_seen_subcommand_from run" -l docker -r -f -a "{true\t'',false\t''}"
complete -c zkstack -n "__fish_zkstack_using_subcommand prover; and __fish_seen_subcommand_from run" -l tag -r
complete -c zkstack -n "__fish_zkstack_using_subcommand prover; and __fish_seen_subcommand_from run" -l chain -d 'Chain to use' -r
Expand Down
20 changes: 18 additions & 2 deletions zkstack_cli/crates/zkstack/completion/zkstack.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7338,7 +7338,7 @@ _zkstack() {
return 0
;;
zkstack__prover__run)
opts="-v -h --component --round --threads --max-allocation --witness-vector-generator-count --max-allocation --docker --tag --verbose --chain --ignore-prerequisites --help"
opts="-l -h -m -v -h --component --round --threads --max-allocation --light-wvg-count --heavy-wvg-count --max-allocation --docker --tag --verbose --chain --ignore-prerequisites --help"
if [[ ${cur} == -* || ${COMP_CWORD} -eq 3 ]] ; then
COMPREPLY=( $(compgen -W "${opts}" -- "${cur}") )
return 0
Expand All @@ -7360,14 +7360,30 @@ _zkstack() {
COMPREPLY=($(compgen -f "${cur}"))
return 0
;;
--witness-vector-generator-count)
--light-wvg-count)
COMPREPLY=($(compgen -f "${cur}"))
return 0
;;
-l)
COMPREPLY=($(compgen -f "${cur}"))
return 0
;;
--heavy-wvg-count)
COMPREPLY=($(compgen -f "${cur}"))
return 0
;;
-h)
COMPREPLY=($(compgen -f "${cur}"))
return 0
;;
--max-allocation)
COMPREPLY=($(compgen -f "${cur}"))
return 0
;;
-m)
COMPREPLY=($(compgen -f "${cur}"))
return 0
;;
--docker)
COMPREPLY=($(compgen -W "true false" -- "${cur}"))
return 0
Expand Down

0 comments on commit cdaeee0

Please sign in to comment.