emma icon indicating copy to clipboard operation
emma copied to clipboard

[TEST] Create micro benchmarks for compiler transformations

Open joroKr21 opened this issue 7 years ago • 3 comments

This will be useful for papers / thesis.

Use ScalaMeter to create the infrastructure for micro benchmarks of compiler transformations. This will also give us some simple statistics and reporting for free. Benchmarks can then be run on a bunch of Scala code like scala-repos. The tricky part is making sure the transformations are lenient enough to not fail on random input.

After this we can define a few variants of the core transformations like ANF and DSCF to compare: using the Transversers API, recursive methods, stateful transformers from scalac, quasiquotes vs the AST API, etc.

  • [x] Benchmarking infrastructure
  • [ ] Benchmarks for ANF
  • [ ] Benchmarks for DSCF

joroKr21 avatar Mar 30 '17 17:03 joroKr21

@joroKr21 I had to use this snippet in my pom.xml to add scalameter (the XML derived from the SBT config attempts to resolve the org.mongodb:casbah_2.11:3.1.1 with type jar and fails).

<!-- Scalameter -->
<dependency>
    <groupId>com.storm-enroute</groupId>
    <artifactId>scalameter_2.11</artifactId>
    <version>0.8.2</version>
    <exclusions>
        <exclusion>
            <groupId>org.mongodb</groupId>
            <artifactId>casbah_2.11</artifactId>
        </exclusion>
    </exclusions>
</dependency>
<dependency>
    <groupId>org.mongodb</groupId>
    <artifactId>casbah_2.11</artifactId>
    <version>3.1.1</version>
    <type>pom</type>
</dependency>

I reported the issue in the scalameter GitHub repository.

aalexandrov avatar Apr 05 '17 10:04 aalexandrov

Somehow I don't have this problem.

joroKr21 avatar Apr 05 '17 19:04 joroKr21

Maybe you had the packages cached in your local repository already.

Try running

rm -Rf ~/.m2/repository/org/mongodb/casbah_2.11
mvn dependency:resolve

aalexandrov avatar Apr 05 '17 20:04 aalexandrov