From 40f2e14fcd85f8e6bfae0201a89c397f68fedf4d Mon Sep 17 00:00:00 2001 From: Liu Fengyun Date: Thu, 4 Mar 2021 10:53:37 +0100 Subject: [PATCH 1/2] Add micro bench test about tuples --- tests/bench/tuple.scala | 9 +++++++++ 1 file changed, 9 insertions(+) create mode 100644 tests/bench/tuple.scala diff --git a/tests/bench/tuple.scala b/tests/bench/tuple.scala new file mode 100644 index 000000000000..b8a8e680f796 --- /dev/null +++ b/tests/bench/tuple.scala @@ -0,0 +1,9 @@ +object Test { + val xs0 = (1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16) + assert(xs0(15) == 16) + // 2.787s + + val xs1 = xs0 ++ xs0 + assert(xs1(31) == 16) + // 3.354s +} From 34e124dd9d542021d6d1775b3c1d66e84611a6f2 Mon Sep 17 00:00:00 2001 From: Liu Fengyun Date: Thu, 4 Mar 2021 16:42:48 +0100 Subject: [PATCH 2/2] Enable deep type check --- .../dotty/tools/dotc/BootstrappedOnlyCompilationTests.scala | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/compiler/test/dotty/tools/dotc/BootstrappedOnlyCompilationTests.scala b/compiler/test/dotty/tools/dotc/BootstrappedOnlyCompilationTests.scala index d0e1a2c1540c..e4eae741edbd 100644 --- a/compiler/test/dotty/tools/dotc/BootstrappedOnlyCompilationTests.scala +++ b/compiler/test/dotty/tools/dotc/BootstrappedOnlyCompilationTests.scala @@ -24,7 +24,7 @@ class BootstrappedOnlyCompilationTests { @Test def posMacros: Unit = { implicit val testGroup: TestGroup = TestGroup("compilePosMacros") aggregateTests( - compileFilesInDir("tests/bench", defaultOptions), + compileFilesInDir("tests/bench", defaultOptions.without("-Yno-deep-subtypes")), compileFilesInDir("tests/pos-macros", defaultOptions), compileFilesInDir("tests/pos-custom-args/semanticdb", defaultOptions.and("-Xsemanticdb")), compileDir("tests/pos-special/i7592", defaultOptions.and("-Yretain-trees")),