Karoy Lorentey
faa535ffb2
Merge pull request #20463 from lorentey/remove-random-fill
...
[stdib] Remove RandomNumberGenerator._fill(bytes:)
2018-11-09 21:51:35 +00:00
Michael Ilseman
08d83d0678
[stdlib] Expunge FixedArray from ABI
2018-11-09 13:47:22 -08:00
Michael Ilseman
4ddfd30787
[stdlib] Remove dead code
2018-11-09 13:39:59 -08:00
Harlan Haskins
703c5715cf
Merge pull request #20320 from Azoy/random-readability
...
[QoI][stdlib] Improve some random call sites
2018-11-09 11:31:43 -08:00
Richard Wei
4e2147e6f8
Merge branch 'master' into additive-arithmetic
2018-11-09 10:17:58 -08:00
Michael Ilseman
103861b31f
Merge branch 'master' into uniterator
2018-11-09 10:17:05 -08:00
Karoy Lorentey
51be8c7650
[stdib] Remove RandomNumberGenerator._fill(bytes:)
...
This hidden customization point isn’t used in the stdlib anymore.
2018-11-09 17:37:25 +00:00
Johannes Weiss
17e5fa3506
Merge pull request #19421 from weissi/jw-managed-buffer-realloc
...
implement ManagerBuffer.reallocated to allow realloc'ing the storage
2018-11-09 17:14:08 +00:00
Ben Cohen
6aab1c8b0d
Remove last addressWithNativeOwner use ( #20448 )
2018-11-09 06:22:13 -08:00
Karoy Lorentey
adb5627bc2
[stdlib] AnyHashable: Audit remaining inlinability fixmes
2018-11-09 10:37:20 +00:00
Karoy Lorentey
713ff13d58
[stdlib] ManagedBufferPointer: inlinability audit & slight reorganization
2018-11-09 10:37:20 +00:00
Karoy Lorentey
e3a5750aa3
[stdlib] ManagedBufferPointer: Remove _My typealias.
2018-11-09 10:37:20 +00:00
Karoy Lorentey
5efa3755f3
[stdlib] Leave _SwiftNewtypeWrapper hashing/bridging methods inlinable
...
Newtypes are paper-thin wrappers, so it makes sense for their methods to be inlinable.
2018-11-09 10:37:20 +00:00
Michael Ilseman
75943350d2
[String] Give String a custom iterator
...
Gives us modest wins on complex grapheme strings, but up to 40% on
heavy-ASCII strings.
2018-11-08 18:25:01 -08:00
Michael Ilseman
abe101c5b9
[String] Custom iterator for UnicodeScalarView
...
Provide a custom iterator rather than relying a the IndexingIterator,
as an indexing model is less efficient for stateful processing of
strings. Provides around a 30% speedup.
2018-11-08 18:00:39 -08:00
Richard Wei
da50193c93
Update ABI test
2018-11-08 17:07:16 -08:00
Jordan Rose
e7dd1c17b2
Merge pull request #20384 from jrose-apple/witless
...
Require @usableFromInline on associated type witnesses
2018-11-08 16:36:48 -08:00
Azoy
309f46ebba
condense index to one line
2018-11-08 17:50:16 -06:00
David Smith
96691208e9
Bridged Strings should have some different/additional overrides for performance
2018-11-08 11:08:03 -08:00
Richard Wei
394be18449
Merge branch 'master' of github.com:apple/swift into additive-arithmetic
2018-11-08 10:20:13 -08:00
Richard Wei
57facc8daa
Update comments
2018-11-08 10:18:31 -08:00
Johannes Weiss
2d9fa20c6b
implement ManagerBuffer.reallocated to allow realloc'ing the storage
2018-11-08 18:18:23 +00:00
John McCall
87e9fb5560
Use @_borrowed on a few declarations in the stdlib and overlays.
...
Most of the stdlib's properties don't need @_borrowed because they're
@inlinable, but I did find one place in an overlay where it's probably
sensible to make the operation use generalized accessors even if
they're resilient.
2018-11-08 12:19:09 -05:00
Ben Cohen
92d2959a46
Regroup ABI expected list by change
2018-11-08 06:45:20 -08:00
Ben Cohen
b1038e9b9b
Misc inlinability fixes
2018-11-08 06:45:20 -08:00
Max Moiseev
cc9c4fafe4
Merge pull request #20413 from moiseev/no-guards
...
[stdlib] Fix the abi checker test for both assert and no-assert builds
2018-11-07 21:43:12 -08:00
Richard Wei
44c2f7761a
Implement SE-0233 AdditiveArithmetic
2018-11-07 19:43:13 -08:00
Michael Ilseman
019919d667
Merge pull request #20381 from milseman/oldOS
...
[test] Fixup some tests for older OSes and other inconsequential changes
2018-11-07 17:30:18 -08:00
Maxim Moiseev
938094cdd6
[stdlib] Fix the abi checker test for both assert and no-assert builds
...
A few internal functions were defined within the #if
INTERNAL_CHECKS_ENABLED block, which made the results different between
stdlib configurations with assertions enabled and without. Since these
fucntions are internal and are not @inlinable, it is OK to have them
unconditionally.
<rdar://problem/45880586>
2018-11-07 15:59:30 -08:00
Max Moiseev
547b0a9f08
Merge pull request #20382 from moiseev/runtime-buffers
...
[stdlib] Internalize _Buffer32 and _Buffer72
2018-11-07 15:17:43 -08:00
Lance Parker
864de1d01e
Merge pull request #20371 from lancep/ContiguousArrayInlinableAudit
...
[stdlib]@inlinable audit for ContiguousArray
2018-11-07 14:48:06 -08:00
Lance Parker
71f2ddde29
Merge pull request #20377 from lancep/SliceBufferInlinableAudit
...
[stdlib]@inlinable audit for SliceBuffer
2018-11-07 14:47:26 -08:00
Maxim Moiseev
e107fab25b
[stdlib] Internalize _Buffer32 and _Buffer72
2018-11-07 11:25:31 -08:00
Karoy Lorentey
43f3431d9f
[stdlib] Fix 32-bit oversight
2018-11-07 14:53:22 +00:00
Karoy Lorentey
50bd37b49a
[stdlib] Eliminate _HasherCore protocol
2018-11-07 13:45:56 +00:00
Nate Cook
e5c1567957
[stdlib] Switch to a stable sort algorithm ( #19717 )
...
This switches the standard library's sort algorithm from an in-place
introsort to use a modified timsort, a stable, adaptive sort that
merges runs using a temporary buffer. This implementation performs
straight merges instead of adopting timsort's galloping strategy.
In addition to maintaining the relative order of equal/non-comparable
elements, this algorithm outperforms the introsort on data with any
intrinsic structure, such as runs of ascending or descending elements
or a significant number of equality collisions.
2018-11-07 00:05:04 -06:00
Jordan Rose
65fe556c1a
[stdlib] Mark associated type witnesses as @usableFromInline
...
Inlinable code is permitted to rely on these associated types, so we
need to make sure their declarations are printed in the parseable
interface.
Part of rdar://problem/43824052
2018-11-06 17:00:46 -08:00
Michael Ilseman
e19e07fb0e
[string] Undo workaround; NFC
2018-11-06 16:31:23 -08:00
Lance Parker
1938378b3d
All the @inlinables in SliceBuffer are good
2018-11-06 14:57:21 -08:00
Max Moiseev
d3e7d59ff4
Merge pull request #20290 from moiseev/atomic-int
...
[stdlib] Move _stdlib_AtomicInt and friends out of the stdlib
2018-11-06 14:48:46 -08:00
Lance Parker
90fd4ba4d7
All the @inlinables in ContigArray are good
2018-11-06 14:38:09 -08:00
Michael Ilseman
d6206d5094
Merge pull request #20338 from milseman/hot_cocoa
...
[String] Add _CocoaString typealias to all build configurations.
2018-11-06 10:09:09 -08:00
Maxim Moiseev
ca51626fd3
[stdlib] Move _stdlib_AtomicInt and friends out of the stdlib
2018-11-06 09:53:58 -08:00
Maxim Moiseev
f14e9aabd7
Stop using _stdlib_AtomicInt in ThreadLocalStorage
2018-11-06 09:53:58 -08:00
Joe Groff
bf0e3bf8fa
Merge pull request #20326 from jckarter/key-path-true-const
...
IRGen/Runtime: Make key path pattern format true-const.
2018-11-05 20:24:01 -08:00
Michael Ilseman
62549c81e8
[String] Add _CocoaString typealias to all build configurations.
...
Conditionally compiling out _CocoaString from 32-bit string will be
way too unweidly. Fixes Android bots.
2018-11-05 16:48:05 -08:00
Maxim Moiseev
90106444d3
[stdlib] Remove a bunch of unused functions from Runtime.swift.gyb
...
<rdar://problem/45746339>
2018-11-05 15:03:19 -08:00
Joe Groff
65a4531467
IRGen/Runtime: Make key path pattern format true-const.
...
Use relative references instead of pointers so that the pattern can be true-const. Instead of trying
to instantiate a constant key path literal in-place, point to a cache variable that we can store
a pointer to the shared instance into when instantiated. Now that the pattern format has diverged
significantly from the instance format, simplify and refactor the instantiation code using a walker
for the pattern format instead of trying to reuse the code for working with instantiated instances.
rdar://problem/42674576
2018-11-05 12:30:49 -08:00
Michael Ilseman
fee2787eb6
[String] Invalidate breadcrumbs on mutation.
2018-11-05 06:48:56 -08:00
Azoy
68a2a2ca3d
remember to use the generator
2018-11-04 23:24:54 -06:00