Skip to content

Commit ee57234

Browse files
authored
* Fix: typos * Fix: typos * Fix: typos * Fix: typos * Fix: typos * Fix: typo * Fix: typos
1 parent abce66c commit ee57234

7 files changed

+20
-20
lines changed

Diff for: specs/bytecode-proof.md

+4-4
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ The circuit starts by adding a row that contains the bytecode length using `tag
4545

4646
Then it runs over all the bytes of the bytecode in order starting at the byte at position `0`.
4747
Each following row unrolls a single byte (using `tag = Byte` and `value = the actual byte value`) of the bytecode while also storing its position
48-
(`index`), the code hash it's part of (`hash`), and if it is code or not
48+
(`index`), the code hash its part of (`hash`), and if it is code or not
4949
(`is_code`). Also `push_data_size` is filled to match the push table, and `push_data_left` is computed.
5050

5151
All byte data is accumulated per byte (with one byte per row) into `value_rlc` as follows, where r is a challenge:
@@ -68,7 +68,7 @@ next.push_data_left := cur.byte_push_size if cur.is_code else cur.push_data_left
6868

6969
The fixed columns `q_first` and `q_last` should be zero for all rows, except the first one where `q_first := 1` and the last one where `q_last := 1`.
7070

71-
## Circuit constrains
71+
## Circuit constraints
7272

7373
All circuit constraints are based on the current row (`cur`) and the `next` row.
7474

@@ -100,7 +100,7 @@ This way we make sure is_code and next.push_data_left have the right values.
100100

101101
### cur.tag == Header and next.tag == Header
102102

103-
We are in a transition from a empty bytecode to the begining of another bytecode that could be empty or not.
103+
We are in a transition from a empty bytecode to the beginning of another bytecode that could be empty or not.
104104

105105
Hence:
106106
```
@@ -110,7 +110,7 @@ assert cur.hash == EMPTY_HASH
110110

111111
### cur.tag == Header and next.tag == Byte
112112

113-
We are at the begining of a non-empty bytecode.
113+
We are at the beginning of a non-empty bytecode.
114114

115115
Hence:
116116

Diff for: specs/copy-proof.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ First, the circuit adds common constraints that applied to every rows in the cir
3434
- `Address` increase by 1 in the next copy step.
3535
- The transition constraints for `RwCounter` and `RwcIncreaseLeft` column
3636
- define `rw_diff` to be 1 if the `Type` is `Memory` or `TxLog` and `Padding` is 0 in the current row; otherwise 0.
37-
- when it's not the last row in a copy event (`is_last == 0`), `RwCounter` increases by `rw_diff` and `RwcIncreaseLeft` decrases by `rw_diff`.
37+
- when it's not the last row in a copy event (`is_last == 0`), `RwCounter` increases by `rw_diff` and `RwcIncreaseLeft` decreases by `rw_diff`.
3838
- over all rows, the `rlc_acc` remains the same.
3939
- when it's the last row in a copy event (`is_last == 1`), `RwcIncreaseLeft` is equal to `rw_diff`.
4040
- when it's the last row of a copy event (`is_last == 1`) and `is_rlc_acc == 1`, the row `value` should equal the row `rlc_acc`.

Diff for: specs/evm-proof.md

+4-4
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
The EVM proof argues the transition of state trie root is valid by verifying all the included transactions in a block have correct execution results.
44

5-
EVM circuit re-implements the EVM, but in a perspective of verification, which means the prover can help provide hints as long as it's does not contradict the result. For example, the prover can give hints about if this call is going to revert or not, or if this opcode encounters an error or not, then the EVM circuit can verify that execution results is correct.
5+
EVM circuit re-implements the EVM, but in a perspective of verification, which means the prover can help provide hints as long as it does not contradict the result. For example, the prover can give hints about if this call is going to revert or not, or if this opcode encounters an error or not, then the EVM circuit can verify that execution results is correct.
66

77
The included transactions in a block could be simple ether transfers, contract creations, or contract interactions, and because each transaction has variable execution trace, we can't have fixed circuit layout to verify specific logic in specific region, we instead need a chip to be able to verify all possible logics, and this chip repeats itself to fill the whole circuit.
88

@@ -24,7 +24,7 @@ We call the list of random read-write access records `BusMapping` because it act
2424
| Target | Index | Accessible By | Description |
2525
| ------------------------------------- | ----------------- | --------------- | ------------------------------------------------------------------ |
2626
| [`Block`](#Block) | `{enum}` | `Read` | Block constant decided before executing the block |
27-
| [`BlockHash`](#BlockHash) | `{index}` | `Read` | Previous 256 block hashes as a encoded word array |
27+
| [`BlockHash`](#BlockHash) | `{index}` | `Read` | Previous 256 block hashes as an encoded word array |
2828
| [`AccountNonce`](#AccountNonce) | `{address}` | `Read`, `Write` | Account's nonce |
2929
| [`AccountBalance`](#AccountBalance) | `{address}` | `Read`, `Write` | Account's balance |
3030
| [`AccountCodeHash`](#AccountCodeHash) | `{address}` | `Read`, `Write` | Account's code hash |
@@ -34,7 +34,7 @@ We call the list of random read-write access records `BusMapping` because it act
3434
| [`CallCalldata`](#CallCalldata) | `{id}.{index}` | `Read` | Call's calldata as a byte array (only for EOA calls) |
3535
| [`CallSignature`](#CallSignature) | `{id}.{index}` | `Read` | Call's signature as a byte array (only for EOA calls) |
3636
| [`CallState`](#CallState) | `{id}.{enum}` | `Read`, `Write` | Call's internal state |
37-
| [`CallStateStack`](#CallStateStack) | `{id}.{index}` | `Read`, `Write` | Call's stack as a encoded word array |
37+
| [`CallStateStack`](#CallStateStack) | `{id}.{index}` | `Read`, `Write` | Call's stack as an encoded word array |
3838
| [`CallStateMemory`](#CallStateMemory) | `{id}.{index}` | `Read`, `Write` | Call's memory as a byte array |
3939

4040
## Circuit Constraints
@@ -78,7 +78,7 @@ Since only `code_hash` encodes account existence, we must be careful to never
7878
read (lookup) another account property unless we have checked that the account
7979
exists. This is because the RwTable in the State Circuit has all the entries
8080
sorted by [Tag, FieldTag], so `CodeHash`, `Nonce` and `Balance` are treated
81-
independently, which means that a lookup to `Nonce` or `Balance` could suceed
81+
independently, which means that a lookup to `Nonce` or `Balance` could succeed
8282
on a non-existing account if the account is created afterwards. For this
8383
reason we must guarantee that:
8484
- A `Nonce` and `Balance` lookup to an account must only be performed if we

Diff for: specs/public_inputs.md

+3-3
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,7 @@ synchronize the State Trie.
117117
## Data to synchronize the State Trie
118118

119119
In order to synchronize the State Trie after a new block (assuming we have the state
120-
of the previous block), we need the at least the following data:
120+
of the previous block), we need at least the following data:
121121

122122
- For each tx
123123
- GasPrice: 256 bits
@@ -188,7 +188,7 @@ later be "uncompressed" (opened) from a contract.
188188

189189
The commitment defined in EIP 4844 uses a different field than our circuits, so
190190
opening it in a circuit is very expensive. Instead, we must prove the equivalence
191-
of the committed raw public inputs (outisde of the circuits) with the witnessed
191+
of the committed raw public inputs (outside of the circuits) with the witnessed
192192
raw public inputs (inside the circuits), with the help of the PublicInputs
193193
circuit.
194194

@@ -220,7 +220,7 @@ Notes:
220220
- With this approach, once we cross the `Aggregation0` circuit, the verification cost of each proof is independent of the "real" number of public inputs (i.e. the number of transactions, the size of call data, the number of block fields, etc.)
221221
- Calculating an RLC of values in a contract is cheap (it just needs `MULMOD`, `ADDMOD`)
222222

223-
The following diagram shows the the public input approach using the RLC shortcut:
223+
The following diagram shows the public input approach using the RLC shortcut:
224224

225225
![](./public_inputs.rev1.png)
226226

Diff for: specs/super_circuit.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ shared among all of them. It contains the following circuits:
2525
- [x] Copy Table
2626
- [x] Block Table
2727

28-
The following diagram shows the relation between this circuits and tables:
28+
The following diagram shows the relation between these circuits and tables:
2929
![](./super_circuit.png)
3030

3131
**Note**: There are some smaller sub-circuits, like the ECDSA circuit and opcode related
@@ -34,6 +34,6 @@ Circuits, so they are not shown in the diagram for clarity.
3434

3535
Putting together all sub-circuits in one allows them to easily make lookups to whatever table is
3636
necessary without the need of having them copied. The main drawback is that the Super Circuit proof
37-
is very large, and therefore its verification its costly. To alleviate this problem a new circuit is
37+
is very large, and therefore its verification is costly. To alleviate this problem a new circuit is
3838
introduced: the Root Circuit, whose function is to verify the Super Circuit proof, generating a much
3939
smaller proof which is cheaper to verify.

Diff for: specs/transactions-proof.md

+4-4
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ to the EVM proof via the transactions table.
77

88
## Transaction encoding
99

10-
Different types of transaction encoding exists. On the first iteration of the zkEVM we will only support Legacy transactions with EIP-155. We plan to add support for Non-Legacy (EIP-2718) transactions later.
10+
Different types of transaction encoding exist. On the first iteration of the zkEVM we will only support Legacy transactions with EIP-155. We plan to add support for Non-Legacy (EIP-2718) transactions later.
1111

1212
### Legacy type:
1313

@@ -143,12 +143,12 @@ difference in usage compared to the Tx Circuit:
143143

144144
1. The lookup table needs to be defined in the MPT for these Tx Circuit
145145
particular lookups (which are separate from the State Trie and Account
146-
Storage Lookups). Here we're building a trie from scratch and getting it's
146+
Storage Lookups). Here we're building a trie from scratch and getting its
147147
root.
148148
2. While the State Trie and Account Storage Trie inserts use leafs that are
149149
bounded in size, for the Transactions Trie, the leafs are the RLP of the
150-
Transaction, which contain a variable size calldata. This means that the
151-
MPT circuit needs to accomodate variable length leaf values.
150+
Transaction, which contains a variable size calldata. This means that the
151+
MPT circuit needs to accommodate variable length leaf values.
152152

153153
Once the first iteration of the MPT (the one that fulfills the needs of the
154154
State Circuit lookups) is finished, we'll work on this.

Diff for: specs/word-encoding.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ word8s = [
6060

6161
The 256 bit word is represented as a random linear combination of its 8 bit words.
6262

63-
The commitment check should gurantee the 32 chunks in 8 bit range.
63+
The commitment check should guarantee the 32 chunks in 8 bit range.
6464

6565
## Addition
6666

@@ -90,7 +90,7 @@ This checks the the relations of `a256 > b256`, `a256 < b256`, `a256 == b256`
9090

9191
We group 8 bit chunks to 16 bit chunks to optimize the table.
9292

93-
The `result` carries the conclusion of the comparision from the higher siganificant chunks all the way down.
93+
The `result` carries the conclusion of the comparison from the higher significant chunks all the way down.
9494

9595
Example:
9696

0 commit comments

Comments
 (0)