Add benchmarks
Opened this issue · 2 comments
vil1 commented
We need a benchmarks
sbt module with benchmarks for the functors produced by all our interpreters.
As satisfying first iteration would:
- define a "meaningful" example schema (complex enough to contain at least one instance of every members of the
Schema
ADT). - for each interpreter, provide an "honest" implementation of the same functor, as it would be implemented "by hand" in real-life. For example, implement a
play.api.libs.json.Reads
using theJson.reads
macro. - compare performances of both the derived and the manually implemented functor to come up with a performance score.
plokhotnyuk commented
Please, do not use the most inefficient JSON library for growing a new one... It will be too hard to spot any changes in performance and allocation rate with it.
Let's compare with one of the fastest, like jsoniter-scala which already has a quite efficient derivation by a macro that is on par with the manual one in runtime.