Skip to content
This repository was archived by the owner on Nov 15, 2023. It is now read-only.

Forward port blake2 storage support#2360

Merged
gavofyork merged 3 commits intomasterfrom
bkchr-port-blake2-stuff
Apr 24, 2019
Merged

Forward port blake2 storage support#2360
gavofyork merged 3 commits intomasterfrom
bkchr-port-blake2-stuff

Conversation

@bkchr
Copy link
Member

@bkchr bkchr commented Apr 24, 2019

gui1117 and others added 2 commits April 24, 2019 08:13
* remove default hash, introduce twox_128 and blake2

* use blake2_128 & create ext_blake2_128

* refactor code

* add benchmark

* factorize generator

* fix

* parameterizable hasher

* some fix

* fix

* fix

* fix

* metadata

* fix

* remove debug print

* map -> blake2_256

* fix test

* fix test

* Apply suggestions from code review

Co-Authored-By: thiolliere <gui.thiolliere@gmail.com>

* impl twox 128 concat (#2353)

* impl twox_128_concat

* comment addressed

* fix

* impl twox_128->64_concat

* fix test
@bkchr bkchr added the A0-please_review Pull request needs code review. label Apr 24, 2019
@bkchr bkchr requested a review from gui1117 April 24, 2019 08:09
Copy link
Contributor

@gui1117 gui1117 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

some insubstancial comments. Everything seems good

input.to_vec()
},
test_blake2_256 => |input| blake2_256(input).to_vec(),
test_blake2_128 => |input| blake2_128(input).to_vec(),
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

did I forget test_twox_64 as well ?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes

groups_impl!(Parens, Paren, Parenthesis, parse_parens);

#[derive(Debug)]
#[derive(Debug, Clone)]
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

hmm I now remember I introduced this Clone before creating the new enum HasherKind. So I very suspect this change is not needed anymore.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As we will remove this anyway, it is no problem.

Co-Authored-By: bkchr <bkchr@users.noreply.github.com>
@gavofyork gavofyork merged commit 0c1674b into master Apr 24, 2019
@gavofyork gavofyork deleted the bkchr-port-blake2-stuff branch April 24, 2019 09:05
MTDK1 pushed a commit to bdevux/substrate that referenced this pull request Jul 10, 2019
* move storage maps to blake2_128 (paritytech#2268)

* remove default hash, introduce twox_128 and blake2

* use blake2_128 & create ext_blake2_128

* refactor code

* add benchmark

* factorize generator

* fix

* parameterizable hasher

* some fix

* fix

* fix

* fix

* metadata

* fix

* remove debug print

* map -> blake2_256

* fix test

* fix test

* Apply suggestions from code review

Co-Authored-By: thiolliere <gui.thiolliere@gmail.com>

* impl twox 128 concat (paritytech#2353)

* impl twox_128_concat

* comment addressed

* fix

* impl twox_128->64_concat

* fix test

* Fix compilation and cleanup some docs

* Apply suggestions from code review

Co-Authored-By: bkchr <bkchr@users.noreply.github.com>
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

A0-please_review Pull request needs code review.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants