Skip to content
Discussion options

You must be logged in to vote

One reason is the perf:

Method iters Mean Allocated
ViaCtor 1000 878.7 us 576 B
ViaCtor_OneCall 1000 881.1 us 552 B
ViaStatic 1000 709.4 us 104 B
ViaCtor 10009 8,980.9 us 579 B
ViaCtor_OneCall 10009 8,788.9 us 555 B
ViaStatic 10009 7,086.3 us 106 B
ViaCtor 100000 87,808.1 us 612 B
ViaCtor_OneCall 100000 87,600.9 us 588 B
ViaStatic 100000 70,670.1 us 131 B

Calling via the static methods is 12% faster for the same inputs (on my machine just now). For PBKDF, you should really be picking a number of iterations based on the maximum amount of time you're willing to churn, so "faster" doesn't mean "faster", it means "I get to pick a bigger number of iterations".

To answ…

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by bartonjs
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants