@@ -232,6 +232,11 @@ object Build {
232232 }
233233 )
234234
235+ lazy val commonBenchmarkSettings = Seq (
236+ mainClass in (Jmh , run) := Some (" dotty.tools.benchmarks.Bench" ), // custom main for jmh:run
237+ javaOptions += " -DBENCH_CLASS_PATH=" + Attributed .data((fullClasspath in Compile ).value).mkString(" " , " :" , " " )
238+ )
239+
235240 // sbt >= 0.13.12 will automatically rewrite transitive dependencies on
236241 // any version in any organization of scala{-library,-compiler,-reflect,p}
237242 // to have organization `scalaOrganization` and version `scalaVersion`
@@ -822,11 +827,13 @@ object Build {
822827
823828 lazy val `dotty-bench` = project.in(file(" bench" )).
824829 dependsOn(`dotty-compiler`).
825- settings(commonNonBootstrappedSettings).
826- settings(
827- mainClass in (Jmh , run) := Some (" dotty.tools.benchmarks.Bench" ), // custom main for jmh:run
828- javaOptions += " -DBENCH_CLASS_PATH=" + Attributed .data((fullClasspath in Compile ).value).mkString(" " , " :" , " " )
829- ).
830+ settings(commonNonBootstrappedSettings ++ commonBenchmarkSettings).
831+ enablePlugins(JmhPlugin )
832+
833+ lazy val `dotty-bench-bootstrapped` = project.in(file(" bench-bootstrapped" )).
834+ dependsOn(`dotty-compiler-bootstrapped`).
835+ settings(commonBootstrappedSettings ++ commonBenchmarkSettings).
836+ settings(unmanagedSourceDirectories in Compile ++= Seq (baseDirectory.value / " .." / " bench" / " src" )).
830837 enablePlugins(JmhPlugin )
831838
832839 // Depend on dotty-library so that sbt projects using dotty automatically
0 commit comments