Daniel Lubarov
aae9e49e90
Merge pull request #696 from mir-protocol/public_memory
...
Public memory, part 1
2022-08-25 23:48:01 -07:00
Daniel Lubarov
66a3999679
Keccak generation tweak
2022-08-25 23:13:29 -07:00
Daniel Lubarov
aa87f2c3ba
Public memory
2022-08-25 20:19:18 -07:00
Daniel Lubarov
fb34b09888
Remove keccak_rust in favor of tiny-keccak
...
`keccak_rust` doesn't seem to have much usage, and it treats `x` as the major axis of its 5x5 input. This is not exactly wrong, since Keccak itself doesn't have a notion of axis order. However, there is a convention for mapping bits of the cube to a flat list of bits, which is
> The mapping between the bits of `s` and those of `a` is `s[w(5y + x) + z] = a[x][y][z]`.
Obeying this convention would be awkward with `keccak_rust` - the words in memory would need to be transposed.
2022-08-24 15:48:02 -07:00
Daniel Lubarov
61819af07d
Improved Keccak implementation
...
Based on the approach @SyxtonPrime described.
In terms of columns, the changes are:
- Store inputs (`A`) as `u32` limbs, rather than individual bits.
- Remove `C_partial`. It was used to store an intermediate product in a 5-way xor, but we've since realized that we can do a 5-way xor directly.
- Add `C_prime`, an intermediate result used to help verify the relation between `A` and `A'`.
2022-08-14 21:33:35 -07:00
Daniel Lubarov
5d74a19ad6
Add test (won't work for a while, but to illustrate)
2022-07-04 18:10:03 -07:00
wborgeaud
f30889b7d7
NUM_REGISTERS -> NUM_COLUMNS
2022-06-29 10:06:46 +02:00
wborgeaud
7812ad242c
s/registers/columns
2022-06-29 10:02:03 +02:00
Daniel Lubarov
e73d01a037
packed_field -> packed (#584 )
...
* `packed_field` -> `packed`
For cleaner imports; "field" is usually clear from context
* fix
2022-06-27 15:07:52 -07:00
Daniel Lubarov
3346d3f902
field_types -> types (#583 )
...
* `field_types` -> `types`
Here too, I think "field" is usually clear from context, e.g. in `use plonky2::field::types::Field;`.
* fixes
* fmt
2022-06-27 12:24:09 -07:00
Daniel Lubarov
410e03349c
extension_field -> extension (#581 )
...
It seems redundant in most contexts, e.g. `use plonky2::field::extension_field::Extendable;`. One could import `extension_field`, but it's not that common in Rust, and `field::extension` is now about as short.
2022-06-27 07:18:21 -07:00
Jacqueline Nabaglo
3aaab765dd
define columns for CTL closer to the constraints ( #573 )
2022-06-21 10:28:44 -07:00
wborgeaud
d9b5d83383
Minor
2022-06-14 16:21:37 +02:00
wborgeaud
1dce18495a
Remove Keccak input limbs
2022-06-14 01:21:17 +02:00
wborgeaud
1356b980c6
Merge pull request #558 from mir-protocol/filtered_ctl
...
Filtered CTL
2022-06-13 19:21:06 +02:00
wborgeaud
bf375390b7
Keccak round flags constraints
2022-06-13 17:41:17 +02:00
wborgeaud
fdd6a7cad8
Wired CPU and Keccak
2022-06-10 21:02:56 +02:00
wborgeaud
8bd6bebdc7
INPUT_LIMBS -> NUM_INPUTS
2022-06-10 19:30:51 +02:00
wborgeaud
30abe19e42
Fix
2022-06-10 00:49:22 +02:00
wborgeaud
413a5a30eb
Merge branch 'main' into keccak_input_registers
2022-06-10 00:14:11 +02:00
wborgeaud
2f3a280b90
Circuit fix
2022-06-09 23:40:58 +02:00
wborgeaud
51f66d4dac
Fix constraint
2022-06-09 23:36:43 +02:00
wborgeaud
8af99cba5d
Progress
2022-06-09 22:42:48 +02:00
wborgeaud
1cc38bb032
Add Keccak input registers
2022-06-09 22:31:33 +02:00
Nicholas Ward
1ad8ec5f33
fix
2022-06-07 10:57:06 -07:00
Nicholas Ward
67167d8e03
use bit operations
2022-06-07 10:57:06 -07:00
Nicholas Ward
8b37d5d25a
fix
2022-06-07 10:57:06 -07:00
Nicholas Ward
3b9cb7a9cf
fmt
2022-06-07 10:57:06 -07:00
Nicholas Ward
cacc073e4e
fix
2022-06-07 10:57:06 -07:00
Nicholas Ward
9d118ca1ef
fix
2022-06-07 10:57:06 -07:00
Nicholas Ward
901525c185
constants crate
2022-06-07 10:57:06 -07:00
Nicholas Ward
f0ed391865
clippy
2022-06-07 10:57:06 -07:00
Nicholas Ward
78b2a5ebef
fixed constraints, in line with generator
2022-06-07 10:57:06 -07:00
Nicholas Ward
52afdae551
cleanup
2022-06-07 10:57:06 -07:00
Nicholas Ward
dc082139c5
fmt
2022-06-07 10:57:06 -07:00
Nicholas Ward
80d5e5375e
fixes, cleanup, and correctness test
2022-06-07 10:57:06 -07:00
Nicholas Ward
9fbae06b61
fmt
2022-06-07 10:57:06 -07:00
Nicholas Ward
04978473d2
fix yay
2022-06-07 10:57:06 -07:00
Nicholas Ward
964849d956
fix
2022-06-07 10:57:06 -07:00
Nicholas Ward
ac18c39044
fmt
2022-06-07 10:57:06 -07:00
Nicholas Ward
69aed6586a
fixes
2022-06-07 10:57:06 -07:00
Nicholas Ward
60c0b4ee79
fix
2022-06-07 10:57:06 -07:00
Nicholas Ward
e34626e9ba
fix
2022-06-07 10:57:06 -07:00
Nicholas Ward
12cb177372
fix
2022-06-07 10:57:06 -07:00
Nicholas Ward
e6d0275f2a
fmt
2022-06-07 10:57:06 -07:00
Nicholas Ward
2c285ca2cd
fixes and debugging
2022-06-07 10:57:06 -07:00
Nicholas Ward
e6880e591b
included everything
2022-06-07 10:57:06 -07:00
Nicholas Ward
db6c3fd811
keccak stark
2022-06-07 10:57:06 -07:00
wborgeaud
12a3155baf
Ignore test instead of failing
2022-05-20 08:34:25 +02:00
wborgeaud
b3f873c66a
Finish test
2022-05-19 11:10:10 +02:00