Commit Graph

1202 Commits

Author SHA1 Message Date
Michael Gottesman
df539948d5 [benchmarks] Add support for building the benchmarks via build-script against the just created toolchain.
Now one can on Darwin/Linux build the benchmarks via swiftpm from build-script by passing in:

```
build-script $NORMAL_ARGS --install-swift --install-swiftpm --install-llbuild --toolchain-benchmarks --swiftpm --llbuild
```

This is done using the infrastructure that BenL added for sourcekit-lsp.
2019-04-07 13:25:31 -07:00
Michael Gottesman
f854547c55 [ownership] Enable ownership verification by default.
I also removed the -verify-sil-ownership flag in favor of a disable flag
-disable-sil-ownership-verifier. I used this on only two tests that still need
work to get them to pass with ownership, but whose problems are well understood,
small corner cases. I am going to fix them in follow on commits. I detail them
below:

1. SILOptimizer/definite_init_inout_super_init.swift. This is a test case where
DI is supposed to error. The only problem is that we crash before we error since
the code emitting by SILGen to trigger this error does not pass ownership
invariants. I have spoken with JoeG about this and he suggested that I fix this
earlier in the compiler. Since we do not run the ownership verifier without
asserts enabled, this should not affect compiler users. Given that it has
triggered DI errors previously I think it is safe to disable ownership here.

2. PrintAsObjC/extensions.swift. In this case, the signature generated by type
lowering for one of the thunks here uses an unsafe +0 return value instead of
doing an autorelease return. The ownership checker rightly flags this leak. This
is going to require either an AST level change or a change to TypeLowering. I
think it is safe to turn this off since it is such a corner case that it was
found by a test that has nothing to do with it.

rdar://43398898
2019-03-25 00:11:52 -07:00
David Smith
d2a59e0edf Add new benchmarks for NSString bridging to cover non-tagged cases 2019-03-21 14:17:39 -07:00
Michael Gottesman
c49fca5522 Merge pull request #23382 from gottesmm/pr-70738274d737cc40c6973417c97dfc24b81133c7
[ownership] Rename enable-sil-ownership => verify-sil-ownership.
2019-03-18 08:44:22 -07:00
Ben Cohen
9250e9fb5b Merge pull request #23294 from PatrickPijnappel/range-overlaps-performance
[test] Add Range Overlaps Benchmark
2019-03-18 07:51:05 -07:00
Michael Gottesman
0dfaa19f9f [ownership] Rename enable-sil-ownership => verify-sil-ownership.
I have been meaning to do this change for a minute, but kept on putting it off.
This describes what is actually happening and is a better name for the option.
2019-03-18 01:31:44 -07:00
Michael Gottesman
7788567444 [benchmark] Compile the benchmark suite with ownership verification enabled. 2019-03-17 23:33:48 -07:00
Patrick Pijnappel
143f25345d [test] Reduce range overlaps benchmark work per N 2019-03-18 14:39:37 +11:00
Patrick Pijnappel
06a2e6d5d2 [test] Add Range overlaps benchmark 2019-03-14 20:26:28 +11:00
Saleem Abdulrasool
d86ead48d4 build: specify vendor for Darwin benchmarks
The build was not specifying the vendor when building the Darwin
benchmarks.  Parts of the SDK rely on the vendor macro (`__APPLE__`) to
be defined which requires that the vendor is specified properly.  Ensure
that we do so.
2019-03-12 17:45:54 -07:00
Pavol Vaskovic
539f2cdcdf [benchmark] Remove DoubleWidthDivision (dead code) 2019-03-01 20:40:18 +01:00
Pavol Vaskovic
b2776f33ce [benchmark] [Equal,Less]Substring setup overhead 2019-03-01 17:56:12 +01:00
Pavol Vaskovic
b7f6813816 [benchmark] ArrayInClass LF + DistinctClassField… 2019-02-28 22:21:02 +01:00
Pavol Vaskovic
6195afcda0 [benchmark] DictionaryOfAnyHashableStrings SO LF
Adjust workload, apply legacyFactor and fix the extra loop of the workload causing the measurable setup overhad.
2019-02-28 22:13:49 +01:00
Pavol Vaskovic
1cbc0b376f Merge pull request #22648 from ianpartridge/benchmark-str2data
[benchmark] Add dataUsingUTF8Encoding()
2019-02-20 15:36:40 +01:00
Pavol Vaskovic
e066d452e8 Merge pull request #22726 from palimondo/cells-interlinked
[benchmark] Finish Naming Convention Support
2019-02-20 12:36:05 +01:00
Pavol Vaskovic
0a49ba8446 Merge pull request #22721 from palimondo/within-cells-interlinked
[benchmark] Janitor Duty: Sweep III
2019-02-20 12:35:46 +01:00
Pavol Vaskovic
40cce2da3d Merge pull request #22707 from palimondo/within-one-stem
[benchmark] Move fake autoreleasepool to TestUtils
2019-02-20 12:35:26 +01:00
Pavol Vaskovic
fc817ba658 Merge pull request #21848 from palimondo/and-dreadfully-distinct
[benchmark] Data.[init,append].Sequence various sizes
2019-02-20 12:34:57 +01:00
Pavol Vaskovic
fae040a763 Merge pull request #22690 from palimondo/against-the-dark
[benchmark] Janitor Duty: Sweep II
2019-02-20 12:34:19 +01:00
Pavol Vaskovic
20365fb437 [benchmark] Fine tune legacyFactor some more 2019-02-20 08:56:38 +01:00
Pavol Vaskovic
6eb85e4780 [benchmark] DictionarySwapAtOfObjects fine-tune LF 2019-02-20 08:00:53 +01:00
Pavol Vaskovic
311ddcec99 [benchmark] DictionaryCompactMapValues tweeks
Extracted run functions and added setUpFunctions.
2019-02-20 01:34:30 +01:00
Pavol Vaskovic
6bfaafa317 [benchmark] DictionarySwap: Extract runFunctions 2019-02-20 01:02:59 +01:00
Pavol Vaskovic
a123b22e57 [benchmark] DictionaryRemove: Extract runFunctions 2019-02-20 01:02:47 +01:00
Pavol Vaskovic
aa977ad3f6 [benchmark] DictionarySwap Setup Overhead 2019-02-19 23:50:50 +01:00
Pavol Vaskovic
f4951e90cd [benchmark] Cosmetic update to Naming Convention
…to match an actual name from extended Flatten family.
Reordered examples to be sorted alphabetically and ascending by lenght because why not?
2019-02-19 23:34:08 +01:00
Pavol Vaskovic
691007b029 [benchmark] LogParser: Accept -?! in bench. names
Extend parser to support benchmark names that include `-?!` in names, to fully support the new Naming Convention from PR #20334.
2019-02-19 23:31:58 +01:00
Pavol Vaskovic
84e7d4dfb8 [benchmark] Adjust Driver’s console output format
…to handle longer benchmark names, assuming maximum length of 40 characters.
2019-02-19 23:28:51 +01:00
Pavol Vaskovic
cdfc31c827 [benchmark] DictionaryRemove Setup Overhead 2019-02-19 22:36:22 +01:00
Pavol Vaskovic
d366105607 Merge branch 'master' into and-dreadfully-distinct 2019-02-19 20:23:05 +01:00
Pavol Vaskovic
9919bc70f7 [benchmark] Remove Array.[init/append] & dead code 2019-02-19 20:12:21 +01:00
Pavol Vaskovic
7896909d23 [benchmark] Move fake autoreleasepool to TestUtils
This workaround for writing cross platform benchmarks is required in multiple performance tests.
2019-02-19 07:50:12 +01:00
Pavol Vaskovic
2704a3e11b [benchmark] DictionaryCompactMapValues Setup Overhead
Refactored to extract setup overhead. Input refference dictionaries are extracted to lazily initialized constants (only first sample includes the overhead, so I’m also skipping the `setUpFunction` with `blackHole`).
2019-02-18 21:32:35 +01:00
Pavol Vaskovic
bf69971048 [benchmark] DictionaryGroupOfObjects Legacy Factor 2019-02-18 18:47:20 +01:00
Ian Partridge
e9ba30a8c4 Remove legacy factor 2019-02-18 09:36:09 +00:00
Pavol Vaskovic
2b60780c98 Update benchmark/single-source/DataBenchmarks.swift
Co-Authored-By: ianpartridge <i.partridge@uk.ibm.com>
2019-02-18 09:34:12 +00:00
Pavol Vaskovic
8e676424c5 [benchmark] Dict.[CopyKeyValue, FilterAllMatch]
Split the composite tests from `DictionatyCopy` and `DictionaryFilter` into individual benchmarks by dictionary size. Lowered the workloads to run faster (more stable results).
2019-02-17 07:10:44 +01:00
Pavol Vaskovic
16af31a39b [benchmark] Remove HashQuadratic
This was obsoleted by DictionaryCopy.
2019-02-17 07:09:14 +01:00
Pavol Vaskovic
003d60131b Merge pull request #22556 from palimondo/a-tall-white-fountain-played
[benchmark] Janitor Duty: Sweep I
2019-02-16 06:38:38 +01:00
Ian Partridge
764f0cfb75 Adjust benchmark naming 2019-02-15 20:24:54 +00:00
Ian Partridge
0fc4f34815 [benchmark] Add StringToDataUsingUTF8Encoding 2019-02-15 12:23:55 +00:00
Michael Ilseman
86724552e8 [benchmark] Add large unicode String<->Data benchmark.
Add a larger unicody workload, beyond the medium-sized ASCII that
currently exists.
2019-02-14 11:45:58 -08:00
Pavol Vaskovic
93adef9c0c [benchmark] DataAppendArray: Fix setup overhead
Extract the array creation out of the main workload function of `DataAppendArray` to stabilize it’s performance in -Onone.
2019-02-14 08:07:15 +01:00
Pavol Vaskovic
796cb4447f [benchmark] ArraySetElement - revert legacy factor
This benchmark had good enough runtime with the original 10x loop multiplier. Lowering it further exposed the setup overhead of creating the 10k element array. Reverting back.
2019-02-14 08:07:14 +01:00
Pavol Vaskovic
9ef04bb92a [benchmark] ArrayLiteral - Fix 0 runtime 2019-02-14 08:07:14 +01:00
Pavol Vaskovic
cac8363025 Merge pull request #20666 from palimondo/i-just-do-eyes
[benchmark] Existential Redux
2019-02-13 05:32:07 +01:00
Andrew Trick
c90838a055 Merge pull request #22541 from atrick/speedup-array-init
Fix performance of array initialization from a generic sequence.
2019-02-12 12:45:30 -08:00
Pavol Vaskovic
776ace0676 [benchmark] Disable ExistentialPerformance
Don’t run the ExistentialPerformance benchmarks as part of the pre-commit suite.
2019-02-12 21:17:31 +01:00
Pavol Vaskovic
3f179f39e0 Increase # of independent samples for changes.
Multimodal benchmarks with significant delta between the modes can report false performance changes when we gather too few independent samples. This increases the minimal number of independent samples from 5 to 10.
Fix for https://bugs.swift.org/browse/SR-9907
2019-02-12 11:42:51 +01:00