27 Commits

Author SHA1 Message Date
Andrew Trick
634087d093 Mark ArrayAppendRepeatCol benchmark unstable
It varies by 2x from run-to-run.

We don't yet have a way to control malloc behavior from the driver.
2022-11-07 11:00:13 -08:00
Dario Rexin
4c484af381 [Benchmarks] Disable a few noisy Array benchmarks (#60705) 2022-08-22 13:18:52 -07:00
Erik Eckstein
5c82b8c32f benchmarks: fix some benchmark unstabilities
* disable unstable benchmark `ArrayPlusEqualArrayOfInt`
* scale (by renaming) `SubstringFromLongStringGeneric` by 10
2022-07-25 14:55:42 +02:00
Erik Eckstein
5ff6308e05 benchmarks: disable some unstable benchmarks
and scale a substring test
2021-09-22 08:39:06 +02:00
Karoy Lorentey
8944591e71 [benchmark] Simplify benchmark registration 2021-09-15 22:08:08 -07:00
Karoy Lorentey
8910b75cfe [benchmark] Stop capitalizing function and variable names 2021-09-15 22:08:07 -07:00
Pavol Vaskovic
20f91e7e08 [benchmark] ArrayAppend fine-tune Legacy Factor
Lowered the workload of string appending bechmarks a bit further, to get them under 1ms in `O` and 10ms in `Onone` builds.

Fine tuned the legacy factor to match original `O` runtimes — the changes are non-linear because of complications from double loop and amortized array growth costs.

These string appending benchmarks along with
* ArrayPlusEqualFiveElementCollection and
* ArrayPlusEqualSingleElementCollection
are likely to show different performance in `Osize` and `Onone` builds because of the non-linearity of their original implementation.
2018-12-07 16:27:06 +01:00
Pavol Vaskovic
150d748cab [benchmark] ArrayAppend Legacy Factor
Cleaned up doubled inner loops and applied legacyFactor to the resulting, more rational, workload sizes.

Factors for string appending benchmarks are not 10, but 11 to compensate for smaller amortized Array resizes. Similarily ArrayPlusEqualFiveElementCollection’s factor is 49.
2018-12-07 15:09:27 +01:00
Pavol Vaskovic
53653de575 [benchmark] Extract setup from ArrayAppend*
ArrayAppendStrings had setup overhead of 10ms (42%). ArrayAppendLazyMap had setup overhead of 24 μs (1%).

ArrayAppendOptionals and ArrayAppendArrayOfInt also had barely visible, small overhead of ~18μs, that was mostly hidden in measurement noise, but I’ve extracted the setup from all places that had 10 000 element array initializations, in preparation for more precise measurement in the future.
2018-10-23 21:12:36 +02:00
Pavol Vaskovic
8617745b39 [benchmark] Gardening: extract tags constant 2018-10-23 20:49:56 +02:00
Pavol Vaskovic
4bbb635fca [benchmark] Gardening: Fix copy/paste comments 2018-10-23 20:49:56 +02:00
Ben Cohen
4694310e51 [stdlib] Some minor cleanup (#18130)
* Remove case destructuring to _

* Remove some Iterator.Element

* Which idiot wrote this? Oh.

* Switch NibbleSort to just use default impls... shouldn't change perf
2018-07-21 17:29:57 -07:00
Michael Ilseman
5bb2e62280 [benchmark] ArrayAppend for substrings.
Add substring-view-oriented array append benchmarks. Put a
getString/getSubstring call into the innermost loop to prevent some
constant folding towards triviality.
2018-04-30 14:01:51 -07:00
Max Moiseev
1dd9d61ded Move all benchmarks to use registerBenchmark and BenchmarkInfo 2017-10-03 18:04:56 -07:00
Erik Eckstein
994c04f943 benchmarks: add another benchmark for appending multiple array elements.
In contrast to the other similar benchmarks, this benchmark starts with a new array each iteration.
2017-04-26 15:06:05 -07:00
Ben Cohen
95988dd29d Add benchmarks for appending UTF8 String views to an array 2017-02-06 14:14:49 -08:00
Ben Ng
3e718d3a26 Add benchmarks for += in ArrayAppend 2017-01-11 22:11:31 -05:00
practicalswift
6d1ae2a39c [gardening] 2016 → 2017 2017-01-06 16:41:22 +01:00
practicalswift
1c5425fff9 [gardening] Fix recently introduced typos. 2016-12-20 10:07:36 +01:00
ben-cohen
313e2954c0 add tests of generic append 2016-12-18 08:21:46 -08:00
Mishal Shah
5eece8860f Revert "SILOptimizer: Replace Array.append(contentsOf: with Array.append(elem…" 2016-12-06 11:26:15 -08:00
Ben Ng
1b10c18b3e SILOptimizer: Replace [].append(contentsOf:) with [].append(element:) 2016-12-05 12:27:42 -05:00
practicalswift
797b80765f [gardening] Use the correct base URL (https://swift.org) in references to the Swift website
Remove all references to the old non-TLS enabled base URL (http://swift.org)
2016-11-20 17:36:03 +01:00
Ben Cohen
edbc41dc54 expanding append(contentsOf:) benchmarks 2016-10-28 09:47:50 -07:00
Ben Cohen
79f1880ca5 Add simple benchmark for append(contentsOf:) 2016-10-24 17:05:00 -07:00
Manav Gabhawala
7928140f79 [SE-0046] Implements consistent function parameter labels by discarding extraneous parameter names and adding _ where necessary 2016-04-06 20:21:58 -04:00
Luke Larson
0356ec8ec3 Add Swift Benchmark Suite 2016-02-08 10:47:58 -08:00