From 61cf97c892f3c1819523a2bbf2dd19436f7c09f9 Mon Sep 17 00:00:00 2001 From: Josh Soref Date: Sun, 17 Apr 2022 15:16:34 -0400 Subject: [PATCH 01/33] spelling: approximate Signed-off-by: Josh Soref --- benchmark/scripts/test_Benchmark_Driver.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/benchmark/scripts/test_Benchmark_Driver.py b/benchmark/scripts/test_Benchmark_Driver.py index bad4ea83a4c7c..6503e919caadc 100644 --- a/benchmark/scripts/test_Benchmark_Driver.py +++ b/benchmark/scripts/test_Benchmark_Driver.py @@ -999,7 +999,7 @@ def test_benchmark_has_constant_memory_use(self): doctor.analyze( { # The threshold of 15 pages was estimated from previous - # measurements. The normal range should be probably aproximated + # measurements. The normal range should be probably approximate # by a function instead of a simple constant. # TODO: re-evaluate normal range from whole SBS "name": "ConstantMemory", From 64e2f7bf4d294cd1209740399fa6dae4a933e149 Mon Sep 17 00:00:00 2001 From: Josh Soref Date: Sun, 17 Apr 2022 15:17:53 -0400 Subject: [PATCH 02/33] spelling: available Signed-off-by: Josh Soref --- benchmark/scripts/compare_perf_tests.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/benchmark/scripts/compare_perf_tests.py b/benchmark/scripts/compare_perf_tests.py index ac48ab4feef3f..609c920a2fe64 100755 --- a/benchmark/scripts/compare_perf_tests.py +++ b/benchmark/scripts/compare_perf_tests.py @@ -311,7 +311,7 @@ def merge(self, r): """Merge two results. Recomputes min, max and mean statistics. If all `samples` are - avaliable, it recomputes all the statistics. + available, it recomputes all the statistics. The use case here is comparing test results parsed from concatenated log files from multiple runs of benchmark driver. """ From 59a1b26867f9adf2fa0559c5cc5f2476f2bcf254 Mon Sep 17 00:00:00 2001 From: Josh Soref Date: Sun, 17 Apr 2022 15:18:32 -0400 Subject: [PATCH 03/33] spelling: benchmarks Signed-off-by: Josh Soref --- benchmark/scripts/run_smoke_bench | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/benchmark/scripts/run_smoke_bench b/benchmark/scripts/run_smoke_bench index fc65c8c6a3480..9b3fa751d427d 100755 --- a/benchmark/scripts/run_smoke_bench +++ b/benchmark/scripts/run_smoke_bench @@ -15,7 +15,7 @@ # # Performs a very fast check which benchmarks regressed and improved. # -# Initially runs the benchmars with a low sample count and just re-runs those +# Initially runs the benchmarks with a low sample count and just re-runs those # benchmarks which differ. # Also reports code size differences. # From a24950485271a2e20f7e535b09a49a21d75704f4 Mon Sep 17 00:00:00 2001 From: Josh Soref Date: Sun, 17 Apr 2022 15:18:36 -0400 Subject: [PATCH 04/33] spelling: between Signed-off-by: Josh Soref --- benchmark/scripts/compare_perf_tests.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/benchmark/scripts/compare_perf_tests.py b/benchmark/scripts/compare_perf_tests.py index 609c920a2fe64..d542dbf2b21f1 100755 --- a/benchmark/scripts/compare_perf_tests.py +++ b/benchmark/scripts/compare_perf_tests.py @@ -22,7 +22,7 @@ class `PerformanceTestSamples` is collection of `Sample`s and their statistics. class `PerformanceTestResult` is a summary of performance test execution. class `LogParser` converts log files into `PerformanceTestResult`s. class `ResultComparison` compares new and old `PerformanceTestResult`s. -class `TestComparator` analyzes changes betweeen the old and new test results. +class `TestComparator` analyzes changes between the old and new test results. class `ReportFormatter` creates the test comparison report in specified format. """ @@ -514,7 +514,7 @@ def results_from_file(log_file): class TestComparator(object): - """Analyzes changes betweeen the old and new test results. + """Analyzes changes between the old and new test results. It determines which tests were `added`, `removed` and which can be compared. It then splits the `ResultComparison`s into 3 groups according to From a252802972cd2fda1948ab87eed3f10f466712cd Mon Sep 17 00:00:00 2001 From: Josh Soref Date: Sun, 17 Apr 2022 15:19:03 -0400 Subject: [PATCH 05/33] spelling: calculation Signed-off-by: Josh Soref --- benchmark/single-source/LuhnAlgoLazy.swift | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/benchmark/single-source/LuhnAlgoLazy.swift b/benchmark/single-source/LuhnAlgoLazy.swift index b6c8d7e87ef2f..c658db3dc3fac 100644 --- a/benchmark/single-source/LuhnAlgoLazy.swift +++ b/benchmark/single-source/LuhnAlgoLazy.swift @@ -219,7 +219,7 @@ let combineDoubleDigits = { (10...18).contains($0) ? $0-9 : $0 } -// first, the lazy version of checksum calcuation +// first, the lazy version of checksum calculation let lazychecksum = { (ccnum: String) -> Bool in ccnum.lazy |> reverse From 89ace02ed7165e58fe0c83f0ebadf8c6b2c825fe Mon Sep 17 00:00:00 2001 From: Josh Soref Date: Sun, 17 Apr 2022 15:19:28 -0400 Subject: [PATCH 06/33] spelling: characterization Signed-off-by: Josh Soref --- benchmark/scripts/test_Benchmark_Driver.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/benchmark/scripts/test_Benchmark_Driver.py b/benchmark/scripts/test_Benchmark_Driver.py index 6503e919caadc..080ed73e779c5 100644 --- a/benchmark/scripts/test_Benchmark_Driver.py +++ b/benchmark/scripts/test_Benchmark_Driver.py @@ -839,7 +839,7 @@ def test_benchmark_runtime_range(self): quantum used by macos scheduler. Linux scheduler's quantum is 6ms. Driver yielding the process before the 10ms quantum elapses helped a lot, but benchmarks with runtimes under 1ms usually exhibit a strong - mode which is best for accurate performance charaterization. + mode which is best for accurate performance characterization. To minimize the number of involuntary context switches that corrupt our measurements, we should strive to stay in the microbenchmark range. From 6d873662a5619cf236ff4f970f3af507de038084 Mon Sep 17 00:00:00 2001 From: Josh Soref Date: Sun, 17 Apr 2022 15:20:09 -0400 Subject: [PATCH 07/33] spelling: coefficient Signed-off-by: Josh Soref --- benchmark/scripts/compare_perf_tests.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/benchmark/scripts/compare_perf_tests.py b/benchmark/scripts/compare_perf_tests.py index d542dbf2b21f1..e73f3cc688549 100755 --- a/benchmark/scripts/compare_perf_tests.py +++ b/benchmark/scripts/compare_perf_tests.py @@ -205,7 +205,7 @@ def running_mean_variance(stats, x): @property def cv(self): - """Coeficient of Variation (%).""" + """Coefficient of Variation (%).""" return (self.sd / self.mean) if self.mean else 0 @property From 49284e449a15ac5b1bf271e659f589237cec97b5 Mon Sep 17 00:00:00 2001 From: Josh Soref Date: Sun, 17 Apr 2022 15:21:14 -0400 Subject: [PATCH 08/33] spelling: computation Signed-off-by: Josh Soref --- benchmark/scripts/compare_perf_tests.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/benchmark/scripts/compare_perf_tests.py b/benchmark/scripts/compare_perf_tests.py index e73f3cc688549..e79c26fdce52d 100755 --- a/benchmark/scripts/compare_perf_tests.py +++ b/benchmark/scripts/compare_perf_tests.py @@ -519,7 +519,7 @@ class TestComparator(object): It determines which tests were `added`, `removed` and which can be compared. It then splits the `ResultComparison`s into 3 groups according to the `delta_threshold` by the change in performance: `increased`, - `descreased` and `unchanged`. Whole computaion is performed during + `descreased` and `unchanged`. Whole computation is performed during initialization and results are provided as properties on this object. The lists of `added`, `removed` and `unchanged` tests are sorted From 8a0bb3f9c116d8c723ba51bd990eccf6715c6839 Mon Sep 17 00:00:00 2001 From: Josh Soref Date: Sun, 17 Apr 2022 15:25:41 -0400 Subject: [PATCH 09/33] spelling: deterministic Signed-off-by: Josh Soref --- benchmark/scripts/test_Benchmark_Driver.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/benchmark/scripts/test_Benchmark_Driver.py b/benchmark/scripts/test_Benchmark_Driver.py index 080ed73e779c5..98e262ab73274 100644 --- a/benchmark/scripts/test_Benchmark_Driver.py +++ b/benchmark/scripts/test_Benchmark_Driver.py @@ -486,7 +486,7 @@ def assert_log_written(out, log_file, content): shutil.rmtree(temp_dir) - def test_deterministing_hashing(self): + def test_deterministic_hashing(self): cmd = ["printenv", "SWIFT_DETERMINISTIC_HASHING"] driver = BenchmarkDriver(["no args"], tests=["ignored"]) self.assertEqual(driver._invoke(cmd).strip(), "1") From f019ebc5d95fee1bcb4a2b53be2ba4e409f234ce Mon Sep 17 00:00:00 2001 From: Josh Soref Date: Sun, 17 Apr 2022 15:27:12 -0400 Subject: [PATCH 10/33] spelling: divisor Signed-off-by: Josh Soref --- benchmark/scripts/Benchmark_Driver | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/benchmark/scripts/Benchmark_Driver b/benchmark/scripts/Benchmark_Driver index 75f194a965bf9..c7970cedb9ecb 100755 --- a/benchmark/scripts/Benchmark_Driver +++ b/benchmark/scripts/Benchmark_Driver @@ -544,7 +544,7 @@ class BenchmarkDoctor(object): caveat = "" if setup == 0 else " (excluding the setup overhead)" log("'%s' execution took at least %d μs%s.", name, runtime, caveat) - def factor(base): # suitable divisior that's integer power of base + def factor(base): # suitable divisor that's integer power of base return int( pow(base, math.ceil(math.log(runtime / float(threshold), base))) ) From afb246e418f4cfffb817cf937718cd0c21a35f51 Mon Sep 17 00:00:00 2001 From: Josh Soref Date: Sun, 17 Apr 2022 15:27:50 -0400 Subject: [PATCH 11/33] spelling: encounter Signed-off-by: Josh Soref --- benchmark/single-source/SortArrayInClass.swift | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/benchmark/single-source/SortArrayInClass.swift b/benchmark/single-source/SortArrayInClass.swift index 6e0d8e6dbd250..906cbd525f288 100644 --- a/benchmark/single-source/SortArrayInClass.swift +++ b/benchmark/single-source/SortArrayInClass.swift @@ -8,7 +8,7 @@ // See https://swift.org/LICENSE.txt for license information // See https://swift.org/CONTRIBUTORS.txt for the list of Swift project authors // -// This benchmark is derived from user code that encoutered a major +// This benchmark is derived from user code that encountered a major // performance problem in normal usage. Contributed by Saleem // Abdulrasool (compnerd). // From 8d880625d3474651cc044317aaf17a28155b3548 Mon Sep 17 00:00:00 2001 From: Josh Soref Date: Sun, 17 Apr 2022 15:29:31 -0400 Subject: [PATCH 12/33] spelling: expected Signed-off-by: Josh Soref --- benchmark/scripts/test_utils.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/benchmark/scripts/test_utils.py b/benchmark/scripts/test_utils.py index c9f634829897e..804e7ea59176a 100644 --- a/benchmark/scripts/test_utils.py +++ b/benchmark/scripts/test_utils.py @@ -83,7 +83,7 @@ def assert_called_with(self, expected_args): ) def assert_called_all_expected(self): - """Verify that all expeced invocations of tested method were called.""" + """Verify that all expected invocations of tested method were called.""" assert self.calls == self.expected, "\nExpected: {0}, \n Called: {1}".format( self.expected, self.calls ) From ea8b681251db1f8d9c6a1067189a28201612a8d9 Mon Sep 17 00:00:00 2001 From: Josh Soref Date: Sun, 17 Apr 2022 15:30:34 -0400 Subject: [PATCH 13/33] spelling: fibonacci Signed-off-by: Josh Soref --- benchmark/utils/TestsUtils.swift | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/benchmark/utils/TestsUtils.swift b/benchmark/utils/TestsUtils.swift index 9a8da75738603..f322830ddb373 100644 --- a/benchmark/utils/TestsUtils.swift +++ b/benchmark/utils/TestsUtils.swift @@ -31,7 +31,7 @@ public enum BenchmarkCategory : String { case exclusivity, differentiation // Algorithms are "micro" that test some well-known algorithm in isolation: - // sorting, searching, hashing, fibonaci, crypto, etc. + // sorting, searching, hashing, fibonacci, crypto, etc. case algorithm // Miniapplications are contrived to mimic some subset of application behavior From b7a5ef370dcd1e4cfec5471f60b44b94722be6f0 Mon Sep 17 00:00:00 2001 From: Josh Soref Date: Sun, 17 Apr 2022 15:30:56 -0400 Subject: [PATCH 14/33] spelling: fulfill Signed-off-by: Josh Soref --- benchmark/scripts/Benchmark_Driver | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/benchmark/scripts/Benchmark_Driver b/benchmark/scripts/Benchmark_Driver index c7970cedb9ecb..2a28372dce308 100755 --- a/benchmark/scripts/Benchmark_Driver +++ b/benchmark/scripts/Benchmark_Driver @@ -718,7 +718,7 @@ class BenchmarkDoctor(object): return measurements def analyze(self, benchmark_measurements): - """Analyze whether benchmark fullfills all requirtements.""" + """Analyze whether benchmark fulfills all requirtements.""" self.log.debug("Analyzing %s", benchmark_measurements["name"]) for rule in self.requirements: rule(benchmark_measurements) From c10c85ae57bc1a8cb62f4ca9bde058ba538e2dbb Mon Sep 17 00:00:00 2001 From: Josh Soref Date: Mon, 18 Apr 2022 22:19:05 -0400 Subject: [PATCH 15/33] spelling: implements Signed-off-by: Josh Soref --- benchmark/scripts/Benchmark_Driver | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/benchmark/scripts/Benchmark_Driver b/benchmark/scripts/Benchmark_Driver index 2a28372dce308..9739cb4941ee5 100755 --- a/benchmark/scripts/Benchmark_Driver +++ b/benchmark/scripts/Benchmark_Driver @@ -20,7 +20,7 @@ Example: Use `Benchmark_Driver -h` for help on available commands and options. -class `BenchmarkDriver` runs performance tests and impements the `run` COMMAND. +class `BenchmarkDriver` runs performance tests and implements the `run` COMMAND. class `BenchmarkDoctor` analyzes performance tests, implements `check` COMMAND. """ From d8ba65d00494e80175c6244c8acc76145a45498d Mon Sep 17 00:00:00 2001 From: Josh Soref Date: Sun, 17 Apr 2022 19:59:09 -0400 Subject: [PATCH 16/33] spelling: into Signed-off-by: Josh Soref --- benchmark/single-source/Breadcrumbs.swift | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/benchmark/single-source/Breadcrumbs.swift b/benchmark/single-source/Breadcrumbs.swift index 3bce3dd4f92d7..d3ed86035ffbf 100644 --- a/benchmark/single-source/Breadcrumbs.swift +++ b/benchmark/single-source/Breadcrumbs.swift @@ -323,7 +323,7 @@ class UTF16ToIdxRange: BenchmarkBase { } /// Split a string into `count` random slices and convert their index ranges -/// into into UTF-16 offset pairs. +/// into UTF-16 offset pairs. class IdxToUTF16Range: BenchmarkBase { let count: Int var inputIndices: [Range] = [] From 922cb2444d9d52da81cb541cda9e8bec2a4e1346 Mon Sep 17 00:00:00 2001 From: Josh Soref Date: Sun, 17 Apr 2022 15:35:59 -0400 Subject: [PATCH 17/33] spelling: intrinsic Signed-off-by: Josh Soref --- benchmark/utils/TestsUtils.swift | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/benchmark/utils/TestsUtils.swift b/benchmark/utils/TestsUtils.swift index f322830ddb373..e70f5ce75dd38 100644 --- a/benchmark/utils/TestsUtils.swift +++ b/benchmark/utils/TestsUtils.swift @@ -55,7 +55,7 @@ public enum BenchmarkCategory : String { // counterproductive. case unstable - // CPU benchmarks represent instrinsic Swift performance. They are useful for + // CPU benchmarks represent intrinsic Swift performance. They are useful for // measuring a fully baked Swift implementation across different platforms and // hardware. The benchmark should also be reasonably applicable to real Swift // code--it should exercise a known performance critical area. Typically these From 8de35251649a43f6c4d2c5391292838345720226 Mon Sep 17 00:00:00 2001 From: Josh Soref Date: Sun, 17 Apr 2022 15:37:15 -0400 Subject: [PATCH 18/33] spelling: markdown Signed-off-by: Josh Soref --- benchmark/scripts/test_Benchmark_Driver.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/benchmark/scripts/test_Benchmark_Driver.py b/benchmark/scripts/test_Benchmark_Driver.py index 98e262ab73274..f647bbc0ca9c2 100644 --- a/benchmark/scripts/test_Benchmark_Driver.py +++ b/benchmark/scripts/test_Benchmark_Driver.py @@ -140,7 +140,7 @@ def test_check_supports_vebose_output(self): self.assertTrue(parse_args(["check", "-v"]).verbose) self.assertTrue(parse_args(["check", "--verbose"]).verbose) - def test_check_supports_mardown_output(self): + def test_check_supports_markdown_output(self): self.assertFalse(parse_args(["check"]).markdown) self.assertTrue(parse_args(["check", "-md"]).markdown) self.assertTrue(parse_args(["check", "--markdown"]).markdown) From ea556706d9d3c6eaf52593990f2e08d22517ef78 Mon Sep 17 00:00:00 2001 From: Josh Soref Date: Sun, 17 Apr 2022 15:37:21 -0400 Subject: [PATCH 19/33] spelling: measure Signed-off-by: Josh Soref --- benchmark/single-source/SortIntPyramids.swift | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/benchmark/single-source/SortIntPyramids.swift b/benchmark/single-source/SortIntPyramids.swift index 791c1dda57688..686c4d0a416c0 100644 --- a/benchmark/single-source/SortIntPyramids.swift +++ b/benchmark/single-source/SortIntPyramids.swift @@ -1,6 +1,6 @@ import TestsUtils -// This benchmark aims to measuare heapSort path of stdlib sorting function. +// This benchmark aims to measure heapSort path of stdlib sorting function. // Datasets in this benchmark are influenced by stdlib partition function, // therefore if stdlib partion implementation changes we should correct these // datasets or disable/skip this benchmark From 7a25a0e39feec05ed4b3ce98531d547fbe080a96 Mon Sep 17 00:00:00 2001 From: Josh Soref Date: Sun, 17 Apr 2022 15:39:33 -0400 Subject: [PATCH 20/33] spelling: occurrences Signed-off-by: Josh Soref --- benchmark/single-source/WordCount.swift | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/benchmark/single-source/WordCount.swift b/benchmark/single-source/WordCount.swift index 0d50d0c439347..fd04bb1851cc9 100644 --- a/benchmark/single-source/WordCount.swift +++ b/benchmark/single-source/WordCount.swift @@ -245,7 +245,7 @@ public func run_WordCountUniqueUTF16(_ n: Int) { } /// Returns an array of all words in the supplied string, along with their -/// number of occurances. The array is sorted by decreasing frequency. +/// number of occurrences. The array is sorted by decreasing frequency. /// (Words are case-sensitive and only support a limited subset of Unicode.) @inline(never) func histogram(for words: S) -> [(String, Int)] From ccd81516700cd6fa71bbc394eb44fcb5e43257b5 Mon Sep 17 00:00:00 2001 From: Josh Soref Date: Sun, 17 Apr 2022 15:39:51 -0400 Subject: [PATCH 21/33] spelling: omitted Signed-off-by: Josh Soref --- benchmark/scripts/test_compare_perf_tests.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/benchmark/scripts/test_compare_perf_tests.py b/benchmark/scripts/test_compare_perf_tests.py index 66792f797e5cd..996cdf2ba8ce7 100644 --- a/benchmark/scripts/test_compare_perf_tests.py +++ b/benchmark/scripts/test_compare_perf_tests.py @@ -247,7 +247,7 @@ def test_init_quantiles(self): def test_init_delta_quantiles(self): # #,TEST,SAMPLES,MIN(μs),𝚫MEDIAN,𝚫MAX # 2-quantile from 2 samples in repeated min, when delta encoded, - # the difference is 0, which is ommited -- only separator remains + # the difference is 0, which is omitted -- only separator remains log = "202,DropWhileArray,2,265,,22" r = PerformanceTestResult(log.split(","), quantiles=True, delta=True) self.assertEqual((r.num_samples, r.min, r.median, r.max), (2, 265, 265, 287)) From 24a42b9df5531c479903b3b32833373508a09179 Mon Sep 17 00:00:00 2001 From: Josh Soref Date: Sun, 17 Apr 2022 15:41:47 -0400 Subject: [PATCH 22/33] spelling: partition Signed-off-by: Josh Soref --- benchmark/single-source/SortIntPyramids.swift | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/benchmark/single-source/SortIntPyramids.swift b/benchmark/single-source/SortIntPyramids.swift index 686c4d0a416c0..3efb2af6276f8 100644 --- a/benchmark/single-source/SortIntPyramids.swift +++ b/benchmark/single-source/SortIntPyramids.swift @@ -2,7 +2,7 @@ import TestsUtils // This benchmark aims to measure heapSort path of stdlib sorting function. // Datasets in this benchmark are influenced by stdlib partition function, -// therefore if stdlib partion implementation changes we should correct these +// therefore if stdlib partition implementation changes we should correct these // datasets or disable/skip this benchmark public let benchmarks = [ BenchmarkInfo( From 495875450ba22ed28dfe8caf701cab499f633b02 Mon Sep 17 00:00:00 2001 From: Josh Soref Date: Sun, 17 Apr 2022 15:42:09 -0400 Subject: [PATCH 23/33] spelling: performance Signed-off-by: Josh Soref --- benchmark/scripts/compare_perf_tests.py | 2 +- benchmark/scripts/run_smoke_bench | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/benchmark/scripts/compare_perf_tests.py b/benchmark/scripts/compare_perf_tests.py index e79c26fdce52d..f76a2f80c3d77 100755 --- a/benchmark/scripts/compare_perf_tests.py +++ b/benchmark/scripts/compare_perf_tests.py @@ -576,7 +576,7 @@ def partition(items, p): class ReportFormatter(object): - """Creates the report from perfromance test comparison in specified format. + """Creates the report from performance test comparison in specified format. `ReportFormatter` formats the `PerformanceTestResult`s and `ResultComparison`s provided by `TestComparator` into report table. diff --git a/benchmark/scripts/run_smoke_bench b/benchmark/scripts/run_smoke_bench index 9b3fa751d427d..949dab4037a7b 100755 --- a/benchmark/scripts/run_smoke_bench +++ b/benchmark/scripts/run_smoke_bench @@ -224,7 +224,7 @@ def measure(driver, tests, i): def merge(results, other_results): - """"Merge the other PreformanceTestResults into the first dictionary.""" + """"Merge the other PerformanceTestResults into the first dictionary.""" for test, result in other_results.items(): results[test].merge(result) return results From ffe6a79acceb25df4c570adff6b2430e9dabae8a Mon Sep 17 00:00:00 2001 From: Josh Soref Date: Sun, 17 Apr 2022 15:42:45 -0400 Subject: [PATCH 24/33] spelling: practice Signed-off-by: Josh Soref --- benchmark/single-source/LuhnAlgoEager.swift | 2 +- benchmark/single-source/LuhnAlgoLazy.swift | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/benchmark/single-source/LuhnAlgoEager.swift b/benchmark/single-source/LuhnAlgoEager.swift index e6b92adb0c08e..34ac7aacd0af7 100644 --- a/benchmark/single-source/LuhnAlgoEager.swift +++ b/benchmark/single-source/LuhnAlgoEager.swift @@ -72,7 +72,7 @@ extension MapSomeSequenceView: Sequence { } // now extend a lazy collection to return that view -// from a call to mapSome. In pracice, when doing this, +// from a call to mapSome. In practice, when doing this, // you should do it for all the lazy wrappers // (i.e. random-access, forward and sequence) extension LazyCollectionProtocol { diff --git a/benchmark/single-source/LuhnAlgoLazy.swift b/benchmark/single-source/LuhnAlgoLazy.swift index c658db3dc3fac..087d1176b8f66 100644 --- a/benchmark/single-source/LuhnAlgoLazy.swift +++ b/benchmark/single-source/LuhnAlgoLazy.swift @@ -72,7 +72,7 @@ extension MapSomeSequenceView: Sequence { } // now extend a lazy collection to return that view -// from a call to mapSome. In pracice, when doing this, +// from a call to mapSome. In practice, when doing this, // you should do it for all the lazy wrappers // (i.e. random-access, forward and sequence) extension LazyCollectionProtocol { From 2f8c3a398e2fdd82d6d671e8a4a629bef41d713a Mon Sep 17 00:00:00 2001 From: Josh Soref Date: Sun, 17 Apr 2022 15:43:04 -0400 Subject: [PATCH 25/33] spelling: preemptive Signed-off-by: Josh Soref --- benchmark/scripts/compare_perf_tests.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/benchmark/scripts/compare_perf_tests.py b/benchmark/scripts/compare_perf_tests.py index f76a2f80c3d77..e28c31d2638ee 100755 --- a/benchmark/scripts/compare_perf_tests.py +++ b/benchmark/scripts/compare_perf_tests.py @@ -111,7 +111,7 @@ def exclude_outliers(self, top_only=False): Experimentally, this rule seems to perform well-enough on the benchmark runtimes in the microbenchmark range to filter out - the environment noise caused by preemtive multitasking. + the environment noise caused by preemptive multitasking. """ lo = ( 0 From 59c6a3e5e9bc78a21a4073916219545b93cbc1bc Mon Sep 17 00:00:00 2001 From: Josh Soref Date: Sun, 17 Apr 2022 15:45:42 -0400 Subject: [PATCH 26/33] spelling: repeated Signed-off-by: Josh Soref --- benchmark/scripts/test_compare_perf_tests.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/benchmark/scripts/test_compare_perf_tests.py b/benchmark/scripts/test_compare_perf_tests.py index 996cdf2ba8ce7..eb66df32ae08f 100644 --- a/benchmark/scripts/test_compare_perf_tests.py +++ b/benchmark/scripts/test_compare_perf_tests.py @@ -257,7 +257,7 @@ def test_init_delta_quantiles(self): def test_init_oversampled_quantiles(self): """When num_samples is < quantile + 1, some of the measurements are repeated in the report summary. Samples should contain only true - values, discarding the repetated artifacts from quantile estimation. + values, discarding the repeated artifacts from quantile estimation. The test string is slightly massaged output of the following R script: subsample <- function(x, q) { From 6f79ab469db7da441cafc701c7edecbe1434ed58 Mon Sep 17 00:00:00 2001 From: Josh Soref Date: Sun, 17 Apr 2022 15:46:19 -0400 Subject: [PATCH 27/33] spelling: requirements Signed-off-by: Josh Soref --- benchmark/scripts/Benchmark_Driver | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/benchmark/scripts/Benchmark_Driver b/benchmark/scripts/Benchmark_Driver index 9739cb4941ee5..dc733207119e7 100755 --- a/benchmark/scripts/Benchmark_Driver +++ b/benchmark/scripts/Benchmark_Driver @@ -718,7 +718,7 @@ class BenchmarkDoctor(object): return measurements def analyze(self, benchmark_measurements): - """Analyze whether benchmark fulfills all requirtements.""" + """Analyze whether benchmark fulfills all requirements.""" self.log.debug("Analyzing %s", benchmark_measurements["name"]) for rule in self.requirements: rule(benchmark_measurements) From 6b6e9ba89f8fbc3c75f5d92a8118090c691f329f Mon Sep 17 00:00:00 2001 From: Josh Soref Date: Sun, 17 Apr 2022 15:46:24 -0400 Subject: [PATCH 28/33] spelling: requires Signed-off-by: Josh Soref --- benchmark/single-source/SIMDReduceInteger.swift | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/benchmark/single-source/SIMDReduceInteger.swift b/benchmark/single-source/SIMDReduceInteger.swift index 67b492a53a7e5..86d830cfa36a8 100644 --- a/benchmark/single-source/SIMDReduceInteger.swift +++ b/benchmark/single-source/SIMDReduceInteger.swift @@ -120,7 +120,7 @@ public func run_SIMDReduceInt32x4_init(_ n: Int) { @inline(never) public func run_SIMDReduceInt32x4_cast(_ n: Int) { // Morally it seems like we "should" be able to use withMemoryRebound - // to SIMD4, but that function requries that the sizes match in + // to SIMD4, but that function requires that the sizes match in // debug builds, so this is pretty ugly. The following "works" for now, // but is probably in violation of the formal model (the exact rules // for "assumingMemoryBound" are not clearly documented). We need a From fa1db32d847531ea88ee32c68b131fdcde8c35fc Mon Sep 17 00:00:00 2001 From: Josh Soref Date: Sun, 17 Apr 2022 15:46:41 -0400 Subject: [PATCH 29/33] spelling: response Signed-off-by: Josh Soref --- benchmark/scripts/test_utils.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/benchmark/scripts/test_utils.py b/benchmark/scripts/test_utils.py index 804e7ea59176a..d551a9912871b 100644 --- a/benchmark/scripts/test_utils.py +++ b/benchmark/scripts/test_utils.py @@ -69,7 +69,7 @@ def __init__(self, responses=None): def expect(self, call_args, response): """Expect invocation of tested method with given arguments. - Stores the canned reponse in the `respond` dictionary. + Stores the canned response in the `respond` dictionary. """ call_args = tuple(call_args) self.expected.append(call_args) From 95d9a255f39004f26f2fb103bf9707e1e6a5e19c Mon Sep 17 00:00:00 2001 From: Josh Soref Date: Sun, 17 Apr 2022 15:51:02 -0400 Subject: [PATCH 30/33] spelling: supports Signed-off-by: Josh Soref --- benchmark/scripts/compare_perf_tests.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/benchmark/scripts/compare_perf_tests.py b/benchmark/scripts/compare_perf_tests.py index e28c31d2638ee..2774638fb5362 100755 --- a/benchmark/scripts/compare_perf_tests.py +++ b/benchmark/scripts/compare_perf_tests.py @@ -225,7 +225,7 @@ class PerformanceTestResult(object): Reported by the test driver (Benchmark_O, Benchmark_Onone, Benchmark_Osize or Benchmark_Driver). - It suppors 2 log formats emitted by the test driver. Legacy format with + It supports 2 log formats emitted by the test driver. Legacy format with statistics for normal distribution (MEAN, SD): #,TEST,SAMPLES,MIN(μs),MAX(μs),MEAN(μs),SD(μs),MEDIAN(μs),MAX_RSS(B) And new quantiles format with variable number of columns: From af6b0c6a92c2747e13f5c0aafd802cc21980a4ec Mon Sep 17 00:00:00 2001 From: Josh Soref Date: Sun, 17 Apr 2022 15:54:10 -0400 Subject: [PATCH 31/33] spelling: unknown Signed-off-by: Josh Soref --- benchmark/scripts/test_compare_perf_tests.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/benchmark/scripts/test_compare_perf_tests.py b/benchmark/scripts/test_compare_perf_tests.py index eb66df32ae08f..1cfc4567aa1b5 100644 --- a/benchmark/scripts/test_compare_perf_tests.py +++ b/benchmark/scripts/test_compare_perf_tests.py @@ -517,7 +517,7 @@ def assert_report_contains(self, texts, report): class TestLogParser(unittest.TestCase): def test_parse_results_csv(self): - """Ignores uknown lines, extracts data from supported formats.""" + """Ignores unknown lines, extracts data from supported formats.""" log = """#,TEST,SAMPLES,MIN(us),MAX(us),MEAN(us),SD(us),MEDIAN(us) 7,Array.append.Array.Int?,20,10,10,10,0,10 21,Bridging.NSArray.as!.Array.NSString,20,11,11,11,0,11 From 614eb2917b0d1114e86131f17bd173771893fb80 Mon Sep 17 00:00:00 2001 From: Josh Soref Date: Sun, 17 Apr 2022 15:55:05 -0400 Subject: [PATCH 32/33] spelling: utilities Signed-off-by: Josh Soref --- benchmark/CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/benchmark/CMakeLists.txt b/benchmark/CMakeLists.txt index 0dae33fa639ba..cc4ad3ec083c6 100644 --- a/benchmark/CMakeLists.txt +++ b/benchmark/CMakeLists.txt @@ -241,7 +241,7 @@ set(SWIFT_BENCHMARK_EXTRA_FLAGS "" CACHE STRING "Extra options to pass to swiftc when building the benchmarks") set(SWIFT_BENCHMARK_UNOPTIMIZED_DRIVER NO CACHE BOOL - "Build the benchmark driver utilites without optimization (default: no)") + "Build the benchmark driver utilities without optimization (default: no)") if (SWIFT_BENCHMARK_BUILT_STANDALONE) # This option's value must match the value of the same option used when From d5f86bba9ae144879398abe72da9057dbcf3bd4b Mon Sep 17 00:00:00 2001 From: Josh Soref Date: Sun, 17 Apr 2022 15:55:20 -0400 Subject: [PATCH 33/33] spelling: verbose Signed-off-by: Josh Soref --- benchmark/scripts/test_Benchmark_Driver.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/benchmark/scripts/test_Benchmark_Driver.py b/benchmark/scripts/test_Benchmark_Driver.py index f647bbc0ca9c2..ae86f54cd0a36 100644 --- a/benchmark/scripts/test_Benchmark_Driver.py +++ b/benchmark/scripts/test_Benchmark_Driver.py @@ -135,7 +135,7 @@ def test_output_dir(self): self.assertIsNone(parse_args(["run"]).output_dir) self.assertEqual(parse_args(["run", "--output-dir", "/log"]).output_dir, "/log") - def test_check_supports_vebose_output(self): + def test_check_supports_verbose_output(self): self.assertFalse(parse_args(["check"]).verbose) self.assertTrue(parse_args(["check", "-v"]).verbose) self.assertTrue(parse_args(["check", "--verbose"]).verbose)