Skip to content

Add benchmarks for a number of NSStringAPI functions#10914

Merged
phausler merged 1 commit intoswiftlang:masterfrom
phausler:NSStringAPI_benchmarks
Jul 13, 2017
Merged

Add benchmarks for a number of NSStringAPI functions#10914
phausler merged 1 commit intoswiftlang:masterfrom
phausler:NSStringAPI_benchmarks

Conversation

@phausler
Copy link
Contributor

This adds a number of simple benchmarks for common NSString APIs that are exposed on String

@phausler
Copy link
Contributor Author

@swift-ci please benchmark

@phausler
Copy link
Contributor Author

@swift-ci please smoke test

@moiseev
Copy link
Contributor

moiseev commented Jul 12, 2017

@phausler 'please benchmark' takes forever, if you're interested in just a rough picture 'please smoke benchmark' is way faster. It will run all the benchmarks but with smaller number of samples, IIRC.

@phausler
Copy link
Contributor Author

phausler commented Jul 12, 2017

gotcha, I will let this run-out for now just to get good baselines.

I presume that the baselines are recorded when the tests are run? or per pull request doing an A/B execution before and after the patch?

My local executions are just hoisting the methods into a benchmark lambda:

import Foundation
#if os(macOS) || os(iOS)
import Darwin
let CLOCK_REALTIME = _CLOCK_REALTIME
#else
import Glibc
#endif

func benchmark(_ samples: Int, _ work: (Int) -> Void) -> Double {
    var start = timespec()
    var end = timespec()
    clock_gettime(CLOCK_REALTIME, &start)
    work(samples)
    clock_gettime(CLOCK_REALTIME, &end)
    return (Double(end.tv_sec) * 1.0e9 + Double(end.tv_nsec)) - (Double(start.tv_sec) * 1.0e9 + Double(start.tv_nsec)) / Double(samples)
}

@moiseev
Copy link
Contributor

moiseev commented Jul 12, 2017

I think it's the latter, as in A/B every time.

@phausler
Copy link
Contributor Author

hmm is there a way I can cancel a build on CI?

@phausler
Copy link
Contributor Author

@swift-ci please smoke benchmark

@moiseev
Copy link
Contributor

moiseev commented Jul 12, 2017

@phausler some of the builds get cancelled automatically once the PR changes, not sure about the benchmark ones.
/cc @shahmishal can you kill the full benchmark build for this PR?

@phausler
Copy link
Contributor Author

I was actually able to abort it

@phausler
Copy link
Contributor Author

interesting followup results:

I was able to eek out performance improvements for the following cases:

run_String_capitalized
run_String_caseInsensitiveCompare_caseDiffering
run_String_caseInsensitiveCompare_equal
run_String_commonPrefix_notShared
run_String_commonPrefix_sharedPrefix_caseInsensitive
run_String_components_CharacterSet
run_String_components_String
run_String_dataUsingEncoding
run_String_enumerateLines
run_String_fastestEncoding_ascii
run_String_fastestEncoding_unicode
run_String_localizedCapitalized

These all were re-writes using either direct _core access or no-copy NSStrings created for accessing the results. Do ephemeral strings have access to _core.startASCII and _core.startUTF16?

So far I am seeing some cases be anywhere from 2x-3x up to 40x improvements. It is also worth noting that some of the tests regress when not using _ns (aka as? NSString).

@moiseev
Copy link
Contributor

moiseev commented Jul 13, 2017

_ephemeralString is just String, the question though is whether obtaining the _ephemeralString from a StringProtocol will regress some of these improvements or not.

@swift-ci
Copy link
Contributor

Build comment file:

Build failed before running benchmark.


Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same typo from #10902

@phausler phausler force-pushed the NSStringAPI_benchmarks branch from ae0cbce to 78cf2aa Compare July 13, 2017 14:44
@phausler
Copy link
Contributor Author

@swift-ci please smoke benchmark

@phausler
Copy link
Contributor Author

@swift-ci please smoke test

@phausler
Copy link
Contributor Author

@swift-ci
Copy link
Contributor

Build comment file:

Optimized (O)

Regression (18)
TEST OLD NEW DELTA SPEEDUP
ReversedArray 49 152 +210.2% 0.32x
PrefixWhileAnySequenceLazy 1492 1845 +23.7% 0.81x
PrefixSequenceLazy 1515 1869 +23.4% 0.81x
DropWhileAnySequenceLazy 2032 2503 +23.2% 0.81x
DropFirstSequenceLazy 2118 2590 +22.3% 0.82x
ProtocolDispatch 2727 3031 +11.1% 0.90x
DropWhileSequence 1549 1696 +9.5% 0.91x
PrefixSequence 1571 1720 +9.5% 0.91x
DropFirstSequence 2095 2292 +9.4% 0.91x
PrefixAnySequence 5002 5383 +7.6% 0.93x
DropWhileAnySequence 6558 7020 +7.0% 0.93x
SuffixAnySequenceLazy 6525 6968 +6.8% 0.94x
Phonebook 5962 6366 +6.8% 0.94x
DropLastAnySequenceLazy 6523 6950 +6.5% 0.94x
DropFirstAnySequence 5756 6119 +6.3% 0.94x
Hanoi 3235 3436 +6.2% 0.94x
DropFirstAnySequenceLazy 5778 6119 +5.9% 0.94x
PrefixAnySequenceLazy 5079 5366 +5.7% 0.95x
Improvement (17)
TEST OLD NEW DELTA SPEEDUP
CharIndexing_ascii_unicodeScalars_Backwards 16265 13234 -18.6% 1.23x
ArrayOfRef 4618 3899 -15.6% 1.18x
BitCount 175 148 -15.4% 1.18x
ArrayPlusEqualThreeElements 1858 1592 -14.3% 1.17x
ArrayPlusEqualFiveElementCollection 5277 4699 -11.0% 1.12x
CStringShortAscii 5435 4894 -10.0% 1.11x
CharIndexing_chinese_unicodeScalars 11859 10763 -9.2% 1.10x
SuffixCountableRangeLazy 11 10 -9.1% 1.10x
CStringLongAscii 4714 4304 -8.7% 1.10x
CharIndexing_ascii_unicodeScalars 15444 14206 -8.0% 1.09x
ArrayOfPOD 180 166 -7.8% 1.08x
ArrayPlusEqualSingleElementCollection 827 771 -6.8% 1.07x
CStringLongNonAscii 2221 2088 -6.0% 1.06x
ArrayAppendGenericStructs 1307 1231 -5.8% 1.06x
ObjectiveCBridgeFromNSDictionaryAnyObjectToStringForced 104225 98569 -5.4% 1.06x
accessInMatSet 19 18 -5.3% 1.06x
ArrayPlusEqualArrayOfInt 629 596 -5.2% 1.06x
No Changes (286)
TEST OLD NEW DELTA SPEEDUP
AngryPhonebook 2976 2982 +0.2% 1.00x (?)
AnyHashableWithAClass 67003 68031 +1.5% 0.98x
Array2D 2059 2042 -0.8% 1.01x (?)
ArrayAppend 777 770 -0.9% 1.01x
ArrayAppendArrayOfInt 600 596 -0.7% 1.01x
ArrayAppendAscii 10009 9928 -0.8% 1.01x
ArrayAppendFromGeneric 598 596 -0.3% 1.00x
ArrayAppendLatin1 30587 30263 -1.1% 1.01x (?)
ArrayAppendLazyMap 938 927 -1.2% 1.01x
ArrayAppendOptionals 1252 1227 -2.0% 1.02x
ArrayAppendRepeatCol 842 839 -0.4% 1.00x (?)
ArrayAppendReserved 534 532 -0.4% 1.00x (?)
ArrayAppendSequence 959 946 -1.4% 1.01x
ArrayAppendStrings 13717 13675 -0.3% 1.00x (?)
ArrayAppendToFromGeneric 599 597 -0.3% 1.00x
ArrayAppendToGeneric 599 596 -0.5% 1.01x
ArrayAppendUTF16 29740 28689 -3.5% 1.04x
ArrayInClass 62 61 -1.6% 1.02x (?)
ArrayLiteral 1244 1226 -1.4% 1.01x
ArrayOfGenericPOD 220 219 -0.5% 1.00x
ArrayOfGenericRef 4030 4006 -0.6% 1.01x (?)
ArraySubscript 1519 1480 -2.6% 1.03x
ArrayValueProp 6 6 +0.0% 1.00x
ArrayValueProp2 6 6 +0.0% 1.00x
ArrayValueProp3 6 6 +0.0% 1.00x
ArrayValueProp4 6 6 +0.0% 1.00x
ByteSwap 120 116 -3.3% 1.03x
Calculator 34 35 +2.9% 0.97x (?)
CaptureProp 4740 4851 +2.3% 0.98x (?)
CharIndexing_chinese_unicodeScalars_Backwards 10173 10032 -1.4% 1.01x
CharIndexing_japanese_unicodeScalars 17485 17004 -2.8% 1.03x
CharIndexing_japanese_unicodeScalars_Backwards 16073 15829 -1.5% 1.02x
CharIndexing_korean_unicodeScalars 14158 13775 -2.7% 1.03x
CharIndexing_korean_unicodeScalars_Backwards 13024 12830 -1.5% 1.02x
CharIndexing_punctuatedJapanese_unicodeScalars 2652 2585 -2.5% 1.03x (?)
CharIndexing_punctuatedJapanese_unicodeScalars_Backwards 2460 2433 -1.1% 1.01x (?)
CharIndexing_punctuated_unicodeScalars 3317 3231 -2.6% 1.03x
CharIndexing_punctuated_unicodeScalars_Backwards 3071 3034 -1.2% 1.01x
CharIndexing_russian_unicodeScalars 12167 11839 -2.7% 1.03x
CharIndexing_russian_unicodeScalars_Backwards 11194 11026 -1.5% 1.02x
CharIndexing_tweet_unicodeScalars 28797 28034 -2.6% 1.03x
CharIndexing_tweet_unicodeScalars_Backwards 26483 26088 -1.5% 1.02x
CharIndexing_utf16_unicodeScalars 82824 83879 +1.3% 0.99x
CharIndexing_utf16_unicodeScalars_Backwards 98005 100936 +3.0% 0.97x
CharIteration_ascii_unicodeScalars 16014 15927 -0.5% 1.01x
CharIteration_ascii_unicodeScalars_Backwards 18542 18147 -2.1% 1.02x
CharIteration_chinese_unicodeScalars 12133 12105 -0.2% 1.00x (?)
CharIteration_chinese_unicodeScalars_Backwards 14034 13736 -2.1% 1.02x
CharIteration_japanese_unicodeScalars 19179 19047 -0.7% 1.01x
CharIteration_japanese_unicodeScalars_Backwards 22209 21728 -2.2% 1.02x
CharIteration_korean_unicodeScalars 15530 15446 -0.5% 1.01x
CharIteration_korean_unicodeScalars_Backwards 17975 17599 -2.1% 1.02x
CharIteration_punctuatedJapanese_unicodeScalars 2904 2980 +2.6% 0.97x
CharIteration_punctuatedJapanese_unicodeScalars_Backwards 3318 3256 -1.9% 1.02x
CharIteration_punctuated_unicodeScalars 3629 3686 +1.6% 0.98x
CharIteration_punctuated_unicodeScalars_Backwards 4163 4084 -1.9% 1.02x (?)
CharIteration_russian_unicodeScalars 13352 13280 -0.5% 1.01x
CharIteration_russian_unicodeScalars_Backwards 15437 15109 -2.1% 1.02x
CharIteration_tweet_unicodeScalars 31561 31293 -0.8% 1.01x
CharIteration_tweet_unicodeScalars_Backwards 36697 35878 -2.2% 1.02x
CharIteration_utf16_unicodeScalars 91220 94119 +3.2% 0.97x
CharIteration_utf16_unicodeScalars_Backwards 134372 137916 +2.6% 0.97x
CharacterLiteralsLarge 6031 6153 +2.0% 0.98x
CharacterLiteralsSmall 403 403 +0.0% 1.00x
Chars 425 419 -1.4% 1.01x (?)
ClassArrayGetter 13 13 +0.0% 1.00x
DeadArray 182 186 +2.2% 0.98x (?)
Dictionary 549 558 +1.6% 0.98x
Dictionary2 1844 1830 -0.8% 1.01x
Dictionary2OfObjects 3316 3295 -0.6% 1.01x (?)
Dictionary3 441 437 -0.9% 1.01x
Dictionary3OfObjects 881 885 +0.5% 1.00x (?)
DictionaryBridge 2535 2520 -0.6% 1.01x (?)
DictionaryGroup 275 276 +0.4% 1.00x
DictionaryGroupOfObjects 1796 1789 -0.4% 1.00x
DictionaryLiteral 1478 1483 +0.3% 1.00x
DictionaryOfObjects 2330 2336 +0.3% 1.00x (?)
DictionaryRemove 2444 2439 -0.2% 1.00x (?)
DictionaryRemoveOfObjects 23278 23671 +1.7% 0.98x
DictionarySwap 429 429 +0.0% 1.00x
DictionarySwapOfObjects 6967 6983 +0.2% 1.00x (?)
DropFirstAnyCollection 57 56 -1.8% 1.02x
DropFirstAnyCollectionLazy 44853 44961 +0.2% 1.00x
DropFirstAnySeqCRangeIter 27159 27155 -0.0% 1.00x (?)
DropFirstAnySeqCRangeIterLazy 27179 27149 -0.1% 1.00x (?)
DropFirstAnySeqCntRange 50 50 +0.0% 1.00x
DropFirstAnySeqCntRangeLazy 50 50 +0.0% 1.00x
DropFirstArray 25 24 -4.0% 1.04x
DropFirstArrayLazy 24 24 +0.0% 1.00x
DropFirstCountableRange 32 32 +0.0% 1.00x
DropFirstCountableRangeLazy 32 32 +0.0% 1.00x
DropLastAnyCollection 22 22 +0.0% 1.00x
DropLastAnyCollectionLazy 14971 14980 +0.1% 1.00x (?)
DropLastAnySeqCRangeIter 4578 4567 -0.2% 1.00x
DropLastAnySeqCRangeIterLazy 4578 4568 -0.2% 1.00x (?)
DropLastAnySeqCntRange 16 16 +0.0% 1.00x
DropLastAnySeqCntRangeLazy 16 16 +0.0% 1.00x
DropLastAnySequence 6679 6808 +1.9% 0.98x (?)
DropLastArray 8 8 +0.0% 1.00x
DropLastArrayLazy 8 8 +0.0% 1.00x
DropLastCountableRange 10 10 +0.0% 1.00x
DropLastCountableRangeLazy 10 10 +0.0% 1.00x
DropLastSequence 557 570 +2.3% 0.98x (?)
DropLastSequenceLazy 557 573 +2.9% 0.97x
DropWhileAnyCollection 69 70 +1.4% 0.99x
DropWhileAnyCollectionLazy 103 103 +0.0% 1.00x
DropWhileAnySeqCRangeIter 21725 21723 -0.0% 1.00x (?)
DropWhileAnySeqCRangeIterLazy 103 103 +0.0% 1.00x
DropWhileAnySeqCntRange 64 64 +0.0% 1.00x
DropWhileAnySeqCntRangeLazy 103 103 +0.0% 1.00x
DropWhileArray 37 37 +0.0% 1.00x
DropWhileArrayLazy 78 78 +0.0% 1.00x
DropWhileCountableRange 35 36 +2.9% 0.97x
DropWhileCountableRangeLazy 68 68 +0.0% 1.00x
DropWhileSequenceLazy 65 65 +0.0% 1.00x
EqualStringSubstring 385 388 +0.8% 0.99x
EqualSubstringString 383 384 +0.3% 1.00x
EqualSubstringSubstring 384 383 -0.3% 1.00x
EqualSubstringSubstringGenericEquatable 387 387 +0.0% 1.00x
ErrorHandling 2889 2897 +0.3% 1.00x (?)
HashTest 1674 1678 +0.2% 1.00x (?)
Histogram 297 298 +0.3% 1.00x
Integrate 263 262 -0.4% 1.00x
IterateData 757 772 +2.0% 0.98x
Join 388 370 -4.6% 1.05x
LazilyFilteredArrays 64481 64823 +0.5% 0.99x (?)
LazilyFilteredRange 3894 3888 -0.2% 1.00x (?)
LessSubstringSubstring 384 384 +0.0% 1.00x
LessSubstringSubstringGenericComparable 382 383 +0.3% 1.00x
LinkedList 7101 7118 +0.2% 1.00x
MapReduce 328 327 -0.3% 1.00x (?)
MapReduceAnyCollection 303 303 +0.0% 1.00x
MapReduceAnyCollectionShort 1990 2028 +1.9% 0.98x (?)
MapReduceClass 3058 3063 +0.2% 1.00x (?)
MapReduceClassShort 4613 4622 +0.2% 1.00x
MapReduceLazyCollection 15 15 +0.0% 1.00x
MapReduceLazyCollectionShort 44 45 +2.3% 0.98x
MapReduceLazySequence 90 90 +0.0% 1.00x
MapReduceSequence 451 451 +0.0% 1.00x
MapReduceShort 1918 1934 +0.8% 0.99x
MapReduceShortString 21 21 +0.0% 1.00x
MapReduceString 96 94 -2.1% 1.02x
Memset 234 234 +0.0% 1.00x
MonteCarloE 10441 10284 -1.5% 1.02x
MonteCarloPi 44001 43992 -0.0% 1.00x (?)
NSDictionaryCastToSwift 5524 5484 -0.7% 1.01x (?)
NSError 290 291 +0.3% 1.00x (?)
NSStringConversion 355 358 +0.8% 0.99x (?)
NopDeinit 21375 21371 -0.0% 1.00x (?)
ObjectAllocation 179 179 +0.0% 1.00x
ObjectiveCBridgeFromNSArrayAnyObject 23092 23033 -0.3% 1.00x (?)
ObjectiveCBridgeFromNSArrayAnyObjectForced 3470 3419 -1.5% 1.01x
ObjectiveCBridgeFromNSArrayAnyObjectToString 39413 39585 +0.4% 1.00x (?)
ObjectiveCBridgeFromNSArrayAnyObjectToStringForced 33460 32878 -1.7% 1.02x (?)
ObjectiveCBridgeFromNSDictionaryAnyObject 119454 119261 -0.2% 1.00x (?)
ObjectiveCBridgeFromNSDictionaryAnyObjectForced 4992 5026 +0.7% 0.99x (?)
ObjectiveCBridgeFromNSDictionaryAnyObjectToString 91350 94293 +3.2% 0.97x (?)
ObjectiveCBridgeFromNSSetAnyObject 64910 65409 +0.8% 0.99x
ObjectiveCBridgeFromNSSetAnyObjectForced 4172 4191 +0.5% 1.00x (?)
ObjectiveCBridgeFromNSSetAnyObjectToString 67419 67659 +0.4% 1.00x (?)
ObjectiveCBridgeFromNSSetAnyObjectToStringForced 69473 68314 -1.7% 1.02x (?)
ObjectiveCBridgeFromNSString 988 987 -0.1% 1.00x
ObjectiveCBridgeFromNSStringForced 1832 1854 +1.2% 0.99x (?)
ObjectiveCBridgeStubDataAppend 3763 3767 +0.1% 1.00x (?)
ObjectiveCBridgeStubDateAccess 182 181 -0.5% 1.01x
ObjectiveCBridgeStubDateMutation 272 272 +0.0% 1.00x
ObjectiveCBridgeStubFromArrayOfNSString 25234 25709 +1.9% 0.98x
ObjectiveCBridgeStubFromNSDate 3484 3483 -0.0% 1.00x (?)
ObjectiveCBridgeStubFromNSDateRef 4145 4034 -2.7% 1.03x
ObjectiveCBridgeStubFromNSString 544 537 -1.3% 1.01x
ObjectiveCBridgeStubFromNSStringRef 140 140 +0.0% 1.00x
ObjectiveCBridgeStubNSDataAppend 2394 2422 +1.2% 0.99x (?)
ObjectiveCBridgeStubNSDateMutationRef 12769 12949 +1.4% 0.99x (?)
ObjectiveCBridgeStubNSDateRefAccess 338 339 +0.3% 1.00x
ObjectiveCBridgeStubToArrayOfNSString 28716 29197 +1.7% 0.98x (?)
ObjectiveCBridgeStubToNSDate 14566 14558 -0.1% 1.00x (?)
ObjectiveCBridgeStubToNSDateRef 3262 3309 +1.4% 0.99x (?)
ObjectiveCBridgeStubToNSString 1530 1516 -0.9% 1.01x (?)
ObjectiveCBridgeStubToNSStringRef 109 108 -0.9% 1.01x (?)
ObjectiveCBridgeStubURLAppendPath 232940 222959 -4.3% 1.04x (?)
ObjectiveCBridgeStubURLAppendPathRef 220050 223344 +1.5% 0.99x (?)
ObjectiveCBridgeToNSArray 28986 28919 -0.2% 1.00x (?)
ObjectiveCBridgeToNSDictionary 44733 44410 -0.7% 1.01x (?)
ObjectiveCBridgeToNSSet 38791 38822 +0.1% 1.00x (?)
ObjectiveCBridgeToNSString 1276 1275 -0.1% 1.00x
ObserverClosure 2281 2286 +0.2% 1.00x
ObserverForwarderStruct 1129 1128 -0.1% 1.00x (?)
ObserverPartiallyAppliedMethod 3747 3757 +0.3% 1.00x (?)
ObserverUnappliedMethod 2739 2743 +0.1% 1.00x (?)
OpenClose 56 56 +0.0% 1.00x
PolymorphicCalls 22 21 -4.5% 1.05x
PopFrontArray 1200 1206 +0.5% 1.00x
PopFrontArrayGeneric 1200 1200 +0.0% 1.00x
PopFrontUnsafePointer 9527 9503 -0.3% 1.00x
PrefixAnyCollection 56 56 +0.0% 1.00x
PrefixAnyCollectionLazy 45068 45053 -0.0% 1.00x (?)
PrefixAnySeqCRangeIter 21382 21357 -0.1% 1.00x (?)
PrefixAnySeqCRangeIterLazy 21353 21379 +0.1% 1.00x (?)
PrefixAnySeqCntRange 50 50 +0.0% 1.00x
PrefixAnySeqCntRangeLazy 50 50 +0.0% 1.00x
PrefixArray 24 25 +4.2% 0.96x
PrefixArrayLazy 25 24 -4.0% 1.04x
PrefixCountableRange 32 32 +0.0% 1.00x
PrefixCountableRangeLazy 32 32 +0.0% 1.00x
PrefixWhileAnyCollection 96 96 +0.0% 1.00x
PrefixWhileAnyCollectionLazy 75 75 +0.0% 1.00x
PrefixWhileAnySeqCRangeIter 12439 12399 -0.3% 1.00x
PrefixWhileAnySeqCRangeIterLazy 75 75 +0.0% 1.00x
PrefixWhileAnySeqCntRange 90 90 +0.0% 1.00x
PrefixWhileAnySeqCntRangeLazy 75 75 +0.0% 1.00x
PrefixWhileAnySequence 13890 14024 +1.0% 0.99x
PrefixWhileArray 62 62 +0.0% 1.00x
PrefixWhileArrayLazy 49 49 +0.0% 1.00x
PrefixWhileCountableRange 36 36 +0.0% 1.00x
PrefixWhileCountableRangeLazy 32 32 +0.0% 1.00x
PrefixWhileSequence 295 294 -0.3% 1.00x (?)
PrefixWhileSequenceLazy 28 28 +0.0% 1.00x
Prims 770 771 +0.1% 1.00x (?)
ProtocolDispatch2 161 168 +4.3% 0.96x
RC4 159 159 +0.0% 1.00x
RGBHistogram 2385 2373 -0.5% 1.01x (?)
RGBHistogramOfObjects 24468 24388 -0.3% 1.00x
RangeAssignment 309 310 +0.3% 1.00x (?)
RecursiveOwnedParameter 2315 2317 +0.1% 1.00x (?)
ReversedBidirectional 28908 29051 +0.5% 1.00x
ReversedDictionary 114 117 +2.6% 0.97x (?)
SetExclusiveOr 3050 2968 -2.7% 1.03x
SetExclusiveOr_OfObjects 9503 9670 +1.8% 0.98x (?)
SetIntersect 308 307 -0.3% 1.00x (?)
SetIntersect_OfObjects 1721 1723 +0.1% 1.00x (?)
SetIsSubsetOf 292 292 +0.0% 1.00x
SetIsSubsetOf_OfObjects 359 359 +0.0% 1.00x
SetUnion 2763 2680 -3.0% 1.03x
SetUnion_OfObjects 8041 7994 -0.6% 1.01x (?)
SevenBoom 1475 1479 +0.3% 1.00x (?)
Sim2DArray 276 276 +0.0% 1.00x
SortLargeExistentials 7994 7830 -2.1% 1.02x
SortLettersInPlace 1159 1149 -0.9% 1.01x
SortSortedStrings 845 881 +4.3% 0.96x
SortStrings 1597 1669 +4.5% 0.96x
SortStringsUnicode 7835 7719 -1.5% 1.02x
StackPromo 22708 22768 +0.3% 1.00x
StaticArray 18 18 +0.0% 1.00x
StrComplexWalk 715 720 +0.7% 0.99x
StrToInt 1979 2010 +1.6% 0.98x
StringAdder 3535 3556 +0.6% 0.99x
StringBuilder 1036 1045 +0.9% 0.99x
StringBuilderLong 943 961 +1.9% 0.98x (?)
StringEdits 114729 114412 -0.3% 1.00x
StringEqualPointerComparison 333 333 +0.0% 1.00x
StringFromLongWholeSubstring 13951 14043 +0.7% 0.99x
StringFromLongWholeSubstringGeneric 22 22 +0.0% 1.00x
StringHasPrefix 16 16 +0.0% 1.00x
StringHasPrefixUnicode 15010 15150 +0.9% 0.99x
StringHasSuffix 16 16 +0.0% 1.00x
StringHasSuffixUnicode 61822 61521 -0.5% 1.00x
StringInterpolation 10843 10781 -0.6% 1.01x (?)
StringMatch 7780 7782 +0.0% 1.00x (?)
StringUTF16Builder 1892 1902 +0.5% 0.99x (?)
StringWalk 1286 1297 +0.9% 0.99x
StringWithCString 55032 55052 +0.0% 1.00x (?)
SubstringComparable 1542 1588 +3.0% 0.97x (?)
SubstringEqualString 1432 1436 +0.3% 1.00x (?)
SubstringEquatable 3454 3429 -0.7% 1.01x (?)
SubstringFromLongString 10 10 +0.0% 1.00x
SubstringFromLongStringGeneric 60 60 +0.0% 1.00x
SuffixAnyCollection 22 22 +0.0% 1.00x
SuffixAnyCollectionLazy 14906 14939 +0.2% 1.00x
SuffixAnySeqCRangeIter 4896 4894 -0.0% 1.00x (?)
SuffixAnySeqCRangeIterLazy 4890 4892 +0.0% 1.00x (?)
SuffixAnySeqCntRange 16 16 +0.0% 1.00x
SuffixAnySeqCntRangeLazy 16 16 +0.0% 1.00x
SuffixAnySequence 6659 6769 +1.7% 0.98x
SuffixArray 8 8 +0.0% 1.00x
SuffixArrayLazy 8 8 +0.0% 1.00x
SuffixCountableRange 10 10 +0.0% 1.00x
SuffixSequence 4385 4386 +0.0% 1.00x (?)
SuffixSequenceLazy 4384 4384 +0.0% 1.00x
SuperChars 80893 83362 +3.1% 0.97x
TwoSum 969 965 -0.4% 1.00x
TypeFlood 0 0 +0.0% 1.00x
UTF8Decode 254 254 +0.0% 1.00x
Walsh 355 357 +0.6% 0.99x
XorLoop 347 347 +0.0% 1.00x
accessGlobal 3 3 +0.0% 1.00x
accessIndependent 2 2 +0.0% 1.00x
Added (17)
TEST MIN MAX MEAN MAX_RSS
String_canBeConverted_ascii 26 26 26 3719168
String_canBeConverted_utf16 14 15 14 3700053
String_canBeConverted_utf8 14 15 14 3682304
String_capitalized 10609 10613 10610 3758763
String_caseInsensitiveCompare_caseDiffering 6245 6510 6334 3708245
String_caseInsensitiveCompare_equal 6112 6115 6113 3712341
String_caseInsensitiveCompare_notEqual 62 63 63 3695957
String_commonPrefix_notShared 745 749 747 3732821
String_commonPrefix_sharedPrefix 775 783 780 10211328
String_commonPrefix_sharedPrefix_caseInsensitive 786 790 788 10147157
String_components_CharacterSet 266149 270834 268134 124515669
String_components_String 322673 336964 327444 114701653
String_dataUsingEncoding 1951 1964 1959 247970475
String_enumerateLines 234412 235212 234860 3768320
String_fastestEncoding_ascii 14 14 14 3690496
String_fastestEncoding_unicode 14 14 14 3776512
String_localizedCapitalized 10612 10615 10613 4468736

Unoptimized (Onone)

Regression (3)
TEST OLD NEW DELTA SPEEDUP
Memset 43955 49776 +13.2% 0.88x
Calculator 1110 1215 +9.5% 0.91x
StringEqualPointerComparison 2300 2448 +6.4% 0.94x
Improvement (3)
TEST OLD NEW DELTA SPEEDUP
Sim2DArray 33893 30017 -11.4% 1.13x
MapReduceLazyCollection 35645 32892 -7.7% 1.08x
ProtocolDispatch 7341 6957 -5.2% 1.06x
No Changes (315)
TEST OLD NEW DELTA SPEEDUP
AngryPhonebook 4987 4916 -1.4% 1.01x
AnyHashableWithAClass 84006 84031 +0.0% 1.00x (?)
Array2D 604349 604654 +0.1% 1.00x (?)
ArrayAppend 3501 3486 -0.4% 1.00x
ArrayAppendArrayOfInt 652 651 -0.2% 1.00x (?)
ArrayAppendAscii 52040 52317 +0.5% 0.99x
ArrayAppendFromGeneric 655 655 +0.0% 1.00x
ArrayAppendGenericStructs 1300 1295 -0.4% 1.00x (?)
ArrayAppendLatin1 73769 74083 +0.4% 1.00x (?)
ArrayAppendLazyMap 210004 210018 +0.0% 1.00x (?)
ArrayAppendOptionals 1298 1310 +0.9% 0.99x
ArrayAppendRepeatCol 214674 214941 +0.1% 1.00x (?)
ArrayAppendReserved 3493 3520 +0.8% 0.99x
ArrayAppendSequence 74567 74134 -0.6% 1.01x (?)
ArrayAppendStrings 13722 13792 +0.5% 0.99x
ArrayAppendToFromGeneric 654 653 -0.2% 1.00x
ArrayAppendToGeneric 654 655 +0.2% 1.00x
ArrayAppendUTF16 74224 74318 +0.1% 1.00x (?)
ArrayInClass 6460 6374 -1.3% 1.01x
ArrayLiteral 1741 1739 -0.1% 1.00x (?)
ArrayOfGenericPOD 3079 3078 -0.0% 1.00x (?)
ArrayOfGenericRef 10060 10082 +0.2% 1.00x
ArrayOfPOD 1833 1832 -0.1% 1.00x
ArrayOfRef 9050 9094 +0.5% 1.00x
ArrayPlusEqualArrayOfInt 652 652 +0.0% 1.00x
ArrayPlusEqualFiveElementCollection 296822 297208 +0.1% 1.00x (?)
ArrayPlusEqualSingleElementCollection 296472 293684 -0.9% 1.01x (?)
ArrayPlusEqualThreeElements 10853 10851 -0.0% 1.00x (?)
ArraySubscript 4194 4205 +0.3% 1.00x (?)
ArrayValueProp 3525 3540 +0.4% 1.00x (?)
ArrayValueProp2 18258 18248 -0.1% 1.00x (?)
ArrayValueProp3 3958 3945 -0.3% 1.00x (?)
ArrayValueProp4 3850 3835 -0.4% 1.00x (?)
BitCount 1682 1684 +0.1% 1.00x (?)
ByteSwap 4298 4257 -1.0% 1.01x (?)
CStringLongAscii 4400 4383 -0.4% 1.00x (?)
CStringLongNonAscii 2275 2272 -0.1% 1.00x (?)
CStringShortAscii 8549 8632 +1.0% 0.99x
CaptureProp 109304 108618 -0.6% 1.01x
CharIndexing_ascii_unicodeScalars 470242 482455 +2.6% 0.97x (?)
CharIndexing_ascii_unicodeScalars_Backwards 521097 523415 +0.4% 1.00x (?)
CharIndexing_chinese_unicodeScalars 356040 366845 +3.0% 0.97x
CharIndexing_chinese_unicodeScalars_Backwards 395361 397542 +0.6% 0.99x (?)
CharIndexing_japanese_unicodeScalars 563247 580456 +3.1% 0.97x (?)
CharIndexing_japanese_unicodeScalars_Backwards 629655 639055 +1.5% 0.99x (?)
CharIndexing_korean_unicodeScalars 456154 466825 +2.3% 0.98x
CharIndexing_korean_unicodeScalars_Backwards 527152 506242 -4.0% 1.04x (?)
CharIndexing_punctuatedJapanese_unicodeScalars 81285 83445 +2.7% 0.97x
CharIndexing_punctuatedJapanese_unicodeScalars_Backwards 92843 91123 -1.9% 1.02x
CharIndexing_punctuated_unicodeScalars 102867 105736 +2.8% 0.97x
CharIndexing_punctuated_unicodeScalars_Backwards 115436 114535 -0.8% 1.01x
CharIndexing_russian_unicodeScalars 390315 400699 +2.7% 0.97x (?)
CharIndexing_russian_unicodeScalars_Backwards 432433 437386 +1.1% 0.99x (?)
CharIndexing_tweet_unicodeScalars 930232 954941 +2.7% 0.97x
CharIndexing_tweet_unicodeScalars_Backwards 1028823 1034830 +0.6% 0.99x (?)
CharIndexing_utf16_unicodeScalars 535683 534880 -0.1% 1.00x (?)
CharIndexing_utf16_unicodeScalars_Backwards 617284 588312 -4.7% 1.05x (?)
CharIteration_ascii_unicodeScalars 179208 180516 +0.7% 0.99x
CharIteration_ascii_unicodeScalars_Backwards 326430 332667 +1.9% 0.98x
CharIteration_chinese_unicodeScalars 136087 141577 +4.0% 0.96x
CharIteration_chinese_unicodeScalars_Backwards 246026 253013 +2.8% 0.97x
CharIteration_japanese_unicodeScalars 215627 223543 +3.7% 0.96x
CharIteration_japanese_unicodeScalars_Backwards 390202 407015 +4.3% 0.96x
CharIteration_korean_unicodeScalars 174428 174726 +0.2% 1.00x
CharIteration_korean_unicodeScalars_Backwards 315965 325281 +2.9% 0.97x
CharIteration_punctuatedJapanese_unicodeScalars 31938 32170 +0.7% 0.99x
CharIteration_punctuatedJapanese_unicodeScalars_Backwards 56376 56551 +0.3% 1.00x (?)
CharIteration_punctuated_unicodeScalars 40187 40362 +0.4% 1.00x
CharIteration_punctuated_unicodeScalars_Backwards 72407 72536 +0.2% 1.00x (?)
CharIteration_russian_unicodeScalars 149809 150505 +0.5% 1.00x (?)
CharIteration_russian_unicodeScalars_Backwards 271418 276110 +1.7% 0.98x (?)
CharIteration_tweet_unicodeScalars 355309 355606 +0.1% 1.00x (?)
CharIteration_tweet_unicodeScalars_Backwards 646425 669302 +3.5% 0.97x (?)
CharIteration_utf16_unicodeScalars 213137 214176 +0.5% 1.00x
CharIteration_utf16_unicodeScalars_Backwards 415172 419452 +1.0% 0.99x
CharacterLiteralsLarge 6276 6202 -1.2% 1.01x
CharacterLiteralsSmall 672 678 +0.9% 0.99x
Chars 48473 48431 -0.1% 1.00x
ClassArrayGetter 987 1001 +1.4% 0.99x
DeadArray 116406 114465 -1.7% 1.02x (?)
Dictionary 3106 3032 -2.4% 1.02x (?)
Dictionary2 3506 3511 +0.1% 1.00x (?)
Dictionary2OfObjects 6119 6167 +0.8% 0.99x (?)
Dictionary3 1307 1315 +0.6% 0.99x (?)
Dictionary3OfObjects 2357 2347 -0.4% 1.00x (?)
DictionaryBridge 2605 2659 +2.1% 0.98x (?)
DictionaryGroup 5228 5139 -1.7% 1.02x
DictionaryGroupOfObjects 8088 8122 +0.4% 1.00x
DictionaryLiteral 8231 8227 -0.0% 1.00x (?)
DictionaryOfObjects 6651 6666 +0.2% 1.00x (?)
DictionaryRemove 21262 21403 +0.7% 0.99x
DictionaryRemoveOfObjects 60470 60910 +0.7% 0.99x
DictionarySwap 5388 5426 +0.7% 0.99x
DictionarySwapOfObjects 22921 22957 +0.2% 1.00x (?)
DropFirstAnyCollection 19922 19912 -0.1% 1.00x
DropFirstAnyCollectionLazy 136746 138442 +1.2% 0.99x (?)
DropFirstAnySeqCRangeIter 30358 30198 -0.5% 1.01x (?)
DropFirstAnySeqCRangeIterLazy 29415 29243 -0.6% 1.01x (?)
DropFirstAnySeqCntRange 20034 19740 -1.5% 1.01x
DropFirstAnySeqCntRangeLazy 20570 19704 -4.2% 1.04x
DropFirstAnySequence 13182 13610 +3.2% 0.97x
DropFirstAnySequenceLazy 13044 13197 +1.2% 0.99x
DropFirstArray 6296 6309 +0.2% 1.00x (?)
DropFirstArrayLazy 44181 44662 +1.1% 0.99x
DropFirstCountableRange 337 340 +0.9% 0.99x
DropFirstCountableRangeLazy 38270 37676 -1.6% 1.02x
DropFirstSequence 12121 11623 -4.1% 1.04x
DropFirstSequenceLazy 11855 12018 +1.4% 0.99x
DropLastAnyCollection 6661 6661 +0.0% 1.00x
DropLastAnyCollectionLazy 46540 45596 -2.0% 1.02x (?)
DropLastAnySeqCRangeIter 44777 44739 -0.1% 1.00x (?)
DropLastAnySeqCRangeIterLazy 44703 44620 -0.2% 1.00x (?)
DropLastAnySeqCntRange 6695 6661 -0.5% 1.01x
DropLastAnySeqCntRangeLazy 6792 6592 -2.9% 1.03x
DropLastAnySequence 29333 29320 -0.0% 1.00x (?)
DropLastAnySequenceLazy 29007 28967 -0.1% 1.00x (?)
DropLastArray 2111 2108 -0.1% 1.00x
DropLastArrayLazy 14736 14903 +1.1% 0.99x (?)
DropLastCountableRange 117 117 +0.0% 1.00x
DropLastCountableRangeLazy 12717 12565 -1.2% 1.01x (?)
DropLastSequence 28646 28942 +1.0% 0.99x
DropLastSequenceLazy 29907 28546 -4.6% 1.05x
DropWhileAnyCollection 25969 25693 -1.1% 1.01x
DropWhileAnyCollectionLazy 28324 28111 -0.8% 1.01x
DropWhileAnySeqCRangeIter 31863 31846 -0.1% 1.00x
DropWhileAnySeqCRangeIterLazy 28618 28265 -1.2% 1.01x
DropWhileAnySeqCntRange 26015 25567 -1.7% 1.02x (?)
DropWhileAnySeqCntRangeLazy 28245 28184 -0.2% 1.00x
DropWhileAnySequence 15412 15098 -2.0% 1.02x
DropWhileAnySequenceLazy 12227 12168 -0.5% 1.00x
DropWhileArray 9859 9846 -0.1% 1.00x
DropWhileArrayLazy 16769 17028 +1.5% 0.98x
DropWhileCountableRange 6268 6250 -0.3% 1.00x
DropWhileCountableRangeLazy 26965 26924 -0.2% 1.00x
DropWhileSequence 14365 14052 -2.2% 1.02x
DropWhileSequenceLazy 11112 11173 +0.5% 0.99x
EqualStringSubstring 663 665 +0.3% 1.00x (?)
EqualSubstringString 661 663 +0.3% 1.00x
EqualSubstringSubstring 775 775 +0.0% 1.00x
EqualSubstringSubstringGenericEquatable 418 418 +0.0% 1.00x
ErrorHandling 6779 6674 -1.5% 1.02x (?)
Hanoi 18268 18604 +1.8% 0.98x (?)
HashTest 18316 18422 +0.6% 0.99x
Histogram 8932 8839 -1.0% 1.01x
Integrate 727 724 -0.4% 1.00x
IterateData 12840 12811 -0.2% 1.00x
Join 1201 1192 -0.7% 1.01x (?)
LazilyFilteredArrays 1703432 1691801 -0.7% 1.01x (?)
LazilyFilteredRange 702423 693487 -1.3% 1.01x
LessSubstringSubstring 780 775 -0.6% 1.01x
LessSubstringSubstringGenericComparable 438 438 +0.0% 1.00x
LinkedList 40392 40377 -0.0% 1.00x (?)
MapReduce 37382 37327 -0.1% 1.00x (?)
MapReduceAnyCollection 37484 37681 +0.5% 0.99x
MapReduceAnyCollectionShort 49913 49962 +0.1% 1.00x (?)
MapReduceClass 42799 42641 -0.4% 1.00x
MapReduceClassShort 53941 55623 +3.1% 0.97x (?)
MapReduceLazyCollectionShort 43679 44132 +1.0% 0.99x
MapReduceLazySequence 25272 25219 -0.2% 1.00x
MapReduceSequence 40785 40655 -0.3% 1.00x (?)
MapReduceShort 49633 49918 +0.6% 0.99x (?)
MapReduceShortString 280 283 +1.1% 0.99x (?)
MapReduceString 2616 2616 +0.0% 1.00x
MonteCarloE 133838 133943 +0.1% 1.00x (?)
MonteCarloPi 52375 52310 -0.1% 1.00x
NSDictionaryCastToSwift 6621 6622 +0.0% 1.00x (?)
NSError 703 702 -0.1% 1.00x (?)
NSStringConversion 389 398 +2.3% 0.98x
NopDeinit 186477 187357 +0.5% 1.00x
ObjectAllocation 1476 1431 -3.0% 1.03x
ObjectiveCBridgeFromNSArrayAnyObject 24648 24763 +0.5% 1.00x
ObjectiveCBridgeFromNSArrayAnyObjectForced 6795 6729 -1.0% 1.01x (?)
ObjectiveCBridgeFromNSArrayAnyObjectToString 40161 40557 +1.0% 0.99x (?)
ObjectiveCBridgeFromNSArrayAnyObjectToStringForced 34033 33934 -0.3% 1.00x (?)
ObjectiveCBridgeFromNSDictionaryAnyObject 124245 123863 -0.3% 1.00x (?)
ObjectiveCBridgeFromNSDictionaryAnyObjectForced 7533 7568 +0.5% 1.00x (?)
ObjectiveCBridgeFromNSDictionaryAnyObjectToString 98575 97923 -0.7% 1.01x (?)
ObjectiveCBridgeFromNSDictionaryAnyObjectToStringForced 105495 100593 -4.6% 1.05x (?)
ObjectiveCBridgeFromNSSetAnyObject 69920 69270 -0.9% 1.01x
ObjectiveCBridgeFromNSSetAnyObjectForced 7396 7382 -0.2% 1.00x (?)
ObjectiveCBridgeFromNSSetAnyObjectToString 75307 73405 -2.5% 1.03x (?)
ObjectiveCBridgeFromNSSetAnyObjectToStringForced 71830 73291 +2.0% 0.98x (?)
ObjectiveCBridgeFromNSString 3903 3865 -1.0% 1.01x (?)
ObjectiveCBridgeFromNSStringForced 2242 2208 -1.5% 1.02x
ObjectiveCBridgeStubDataAppend 3949 3871 -2.0% 1.02x (?)
ObjectiveCBridgeStubDateAccess 1025 1061 +3.5% 0.97x
ObjectiveCBridgeStubDateMutation 485 485 +0.0% 1.00x
ObjectiveCBridgeStubFromArrayOfNSString 25925 25573 -1.4% 1.01x
ObjectiveCBridgeStubFromNSDate 4132 4005 -3.1% 1.03x
ObjectiveCBridgeStubFromNSDateRef 4371 4370 -0.0% 1.00x (?)
ObjectiveCBridgeStubFromNSString 563 568 +0.9% 0.99x (?)
ObjectiveCBridgeStubFromNSStringRef 181 182 +0.6% 0.99x
ObjectiveCBridgeStubNSDataAppend 2682 2769 +3.2% 0.97x
ObjectiveCBridgeStubNSDateMutationRef 16118 15488 -3.9% 1.04x (?)
ObjectiveCBridgeStubNSDateRefAccess 1230 1216 -1.1% 1.01x
ObjectiveCBridgeStubToArrayOfNSString 29686 28812 -2.9% 1.03x
ObjectiveCBridgeStubToNSDate 15319 14706 -4.0% 1.04x (?)
ObjectiveCBridgeStubToNSDateRef 3378 3344 -1.0% 1.01x
ObjectiveCBridgeStubToNSString 1562 1569 +0.4% 1.00x
ObjectiveCBridgeStubToNSStringRef 155 155 +0.0% 1.00x
ObjectiveCBridgeStubURLAppendPath 228434 224662 -1.7% 1.02x (?)
ObjectiveCBridgeStubURLAppendPathRef 230255 225549 -2.0% 1.02x
ObjectiveCBridgeToNSArray 28483 28650 +0.6% 0.99x (?)
ObjectiveCBridgeToNSDictionary 45363 45683 +0.7% 0.99x (?)
ObjectiveCBridgeToNSSet 39451 39634 +0.5% 1.00x (?)
ObjectiveCBridgeToNSString 1301 1305 +0.3% 1.00x
ObserverClosure 6742 6742 +0.0% 1.00x
ObserverForwarderStruct 5007 4782 -4.5% 1.05x
ObserverPartiallyAppliedMethod 8341 8181 -1.9% 1.02x
ObserverUnappliedMethod 8671 8560 -1.3% 1.01x
OpenClose 409 403 -1.5% 1.01x (?)
Phonebook 21758 21984 +1.0% 0.99x (?)
PolymorphicCalls 5427 5439 +0.2% 1.00x (?)
PopFrontArray 9885 9857 -0.3% 1.00x (?)
PopFrontArrayGeneric 8761 8801 +0.5% 1.00x (?)
PopFrontUnsafePointer 97099 99995 +3.0% 0.97x
PrefixAnyCollection 20272 19958 -1.5% 1.02x
PrefixAnyCollectionLazy 138297 137906 -0.3% 1.00x (?)
PrefixAnySeqCRangeIter 23699 23303 -1.7% 1.02x
PrefixAnySeqCRangeIterLazy 23439 23304 -0.6% 1.01x
PrefixAnySeqCntRange 19999 19702 -1.5% 1.02x
PrefixAnySeqCntRangeLazy 20531 19701 -4.0% 1.04x
PrefixAnySequence 10861 10869 +0.1% 1.00x (?)
PrefixAnySequenceLazy 10793 10891 +0.9% 0.99x
PrefixArray 6299 6292 -0.1% 1.00x
PrefixArrayLazy 44176 44650 +1.1% 0.99x
PrefixCountableRange 338 340 +0.6% 0.99x
PrefixCountableRangeLazy 38201 37603 -1.6% 1.02x (?)
PrefixSequence 9839 9473 -3.7% 1.04x
PrefixSequenceLazy 9656 9616 -0.4% 1.00x
PrefixWhileAnyCollection 37637 37153 -1.3% 1.01x
PrefixWhileAnyCollectionLazy 23103 23003 -0.4% 1.00x
PrefixWhileAnySeqCRangeIter 41233 41107 -0.3% 1.00x
PrefixWhileAnySeqCRangeIterLazy 23303 23192 -0.5% 1.00x
PrefixWhileAnySeqCntRange 37666 37069 -1.6% 1.02x
PrefixWhileAnySeqCntRangeLazy 23151 23037 -0.5% 1.00x
PrefixWhileAnySequence 29767 29356 -1.4% 1.01x
PrefixWhileAnySequenceLazy 11382 11153 -2.0% 1.02x
PrefixWhileArray 16865 16847 -0.1% 1.00x
PrefixWhileArrayLazy 14556 15303 +5.1% 0.95x
PrefixWhileCountableRange 18080 17993 -0.5% 1.00x
PrefixWhileCountableRangeLazy 22120 22364 +1.1% 0.99x
PrefixWhileSequence 28760 28408 -1.2% 1.01x (?)
PrefixWhileSequenceLazy 10289 10392 +1.0% 0.99x
Prims 10167 10116 -0.5% 1.01x (?)
ProtocolDispatch2 489 489 +0.0% 1.00x
RC4 20592 19675 -4.5% 1.05x
RGBHistogram 34127 33906 -0.6% 1.01x (?)
RGBHistogramOfObjects 108404 107870 -0.5% 1.00x (?)
RangeAssignment 5917 5751 -2.8% 1.03x
RecursiveOwnedParameter 11262 11124 -1.2% 1.01x
ReversedArray 44040 45094 +2.4% 0.98x
ReversedBidirectional 75756 75911 +0.2% 1.00x (?)
ReversedDictionary 28615 28351 -0.9% 1.01x
SetExclusiveOr 21812 21704 -0.5% 1.00x (?)
SetExclusiveOr_OfObjects 48457 48122 -0.7% 1.01x (?)
SetIntersect 10963 11055 +0.8% 0.99x
SetIntersect_OfObjects 12843 12789 -0.4% 1.00x (?)
SetIsSubsetOf 1684 1695 +0.7% 0.99x
SetIsSubsetOf_OfObjects 1606 1604 -0.1% 1.00x (?)
SetUnion 11972 12048 +0.6% 0.99x
SetUnion_OfObjects 33764 33522 -0.7% 1.01x
SevenBoom 1588 1602 +0.9% 0.99x
SortLargeExistentials 17930 17900 -0.2% 1.00x (?)
SortLettersInPlace 3172 3200 +0.9% 0.99x (?)
SortSortedStrings 1415 1414 -0.1% 1.00x (?)
SortStrings 2450 2449 -0.0% 1.00x (?)
SortStringsUnicode 8863 8822 -0.5% 1.00x
StackPromo 102184 102829 +0.6% 0.99x (?)
StaticArray 4583 4577 -0.1% 1.00x (?)
StrComplexWalk 6778 6774 -0.1% 1.00x (?)
StrToInt 101931 101974 +0.0% 1.00x (?)
StringAdder 3774 3765 -0.2% 1.00x
StringBuilder 6985 6965 -0.3% 1.00x
StringBuilderLong 1125 1114 -1.0% 1.01x
StringEdits 379041 382432 +0.9% 0.99x (?)
StringFromLongWholeSubstring 13670 13703 +0.2% 1.00x (?)
StringFromLongWholeSubstringGeneric 209 206 -1.4% 1.01x
StringHasPrefix 1708 1750 +2.5% 0.98x
StringHasPrefixUnicode 16518 16693 +1.1% 0.99x
StringHasSuffix 1887 1841 -2.4% 1.02x
StringHasSuffixUnicode 63748 63672 -0.1% 1.00x
StringInterpolation 13918 13760 -1.1% 1.01x
StringMatch 31947 31732 -0.7% 1.01x (?)
StringUTF16Builder 7817 7782 -0.4% 1.00x (?)
StringWalk 12935 13265 +2.6% 0.98x
StringWithCString 55989 54750 -2.2% 1.02x
SubstringComparable 4265 4151 -2.7% 1.03x
SubstringEqualString 6402 6401 -0.0% 1.00x (?)
SubstringEquatable 8156 8204 +0.6% 0.99x
SubstringFromLongString 12 12 +0.0% 1.00x
SubstringFromLongStringGeneric 110 111 +0.9% 0.99x
SuffixAnyCollection 6785 6665 -1.8% 1.02x
SuffixAnyCollectionLazy 46194 46061 -0.3% 1.00x (?)
SuffixAnySeqCRangeIter 42182 42225 +0.1% 1.00x
SuffixAnySeqCRangeIterLazy 42225 42173 -0.1% 1.00x (?)
SuffixAnySeqCntRange 6665 6684 +0.3% 1.00x
SuffixAnySeqCntRangeLazy 6798 6606 -2.8% 1.03x
SuffixAnySequence 26997 26827 -0.6% 1.01x
SuffixAnySequenceLazy 26792 26807 +0.1% 1.00x (?)
SuffixArray 2109 2112 +0.1% 1.00x
SuffixArrayLazy 14734 14899 +1.1% 0.99x (?)
SuffixCountableRange 118 118 +0.0% 1.00x
SuffixCountableRangeLazy 12721 12565 -1.2% 1.01x
SuffixSequence 26300 26606 +1.2% 0.99x
SuffixSequenceLazy 26736 26305 -1.6% 1.02x
SuperChars 189867 188812 -0.6% 1.01x (?)
TwoSum 4316 4260 -1.3% 1.01x (?)
TypeFlood 172 172 +0.0% 1.00x
UTF8Decode 37141 37313 +0.5% 1.00x
Walsh 11958 11945 -0.1% 1.00x (?)
XorLoop 23409 23707 +1.3% 0.99x
accessGlobal 190 189 -0.5% 1.01x
accessInMatSet 326 327 +0.3% 1.00x
accessIndependent 123 125 +1.6% 0.98x
Added (17)
TEST MIN MAX MEAN MAX_RSS
String_canBeConverted_ascii 26 26 26 3940352
String_canBeConverted_utf16 14 15 14 3919872
String_canBeConverted_utf8 15 15 15 3930795
String_capitalized 10607 10609 10608 3985408
String_caseInsensitiveCompare_caseDiffering 6243 6267 6253 3929429
String_caseInsensitiveCompare_equal 6114 6298 6176 3929429
String_caseInsensitiveCompare_notEqual 63 71 66 3917141
String_commonPrefix_notShared 746 747 747 3990869
String_commonPrefix_sharedPrefix 775 781 777 10346496
String_commonPrefix_sharedPrefix_caseInsensitive 785 797 789 10323285
String_components_CharacterSet 265465 267661 266609 124911616
String_components_String 322511 322876 322669 125098667
String_dataUsingEncoding 1955 1962 1957 246117717
String_enumerateLines 235531 246730 239272 4003157
String_fastestEncoding_ascii 14 15 14 3903488
String_fastestEncoding_unicode 14 14 14 3981312
String_localizedCapitalized 10610 10621 10615 4721323
Hardware Overview
  Model Name: Mac mini
  Model Identifier: Macmini7,1
  Processor Name: Intel Core i5
  Processor Speed: 2.8 GHz
  Number of Processors: 1
  Total Number of Cores: 2
  L2 Cache (per Core): 256 KB
  L3 Cache: 3 MB
  Memory: 16 GB

@phausler phausler merged commit cf73e56 into swiftlang:master Jul 13, 2017
@phausler
Copy link
Contributor Author

We should probably add more of these to get full coverage but these should do for now to get a feeling of how NSStringAPI extensions are performing with the incoming changes

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants