Carefully track the functions that inject these dependencies, so all
functions that use them can be protected with
@inline(never) @semantics("stdlib_binary_only")
To do this, we introduce a naming convention: the _stdlib_binary_ prefix
distinguishes functions dependent on external frameworks. All callers
of such functions must adopt either the naming convention, or the
attributes above.
This change should unbreak the build.
Swift SVN r25020
These mirrors are the default mirrors that get used for all objective-C
object, including some that aren't defined in Foundation:
import Dispatch
println(dispatch_get_global_queue(0,0))
This example isn't fixed yet, because we need to pull all the string
bridging goop out of Foundation and into the core standard library.
Swift SVN r25012
This change allows us to drop an egregious table-of-function-pointers
hack in favor of a much cleaner hack using SwiftShims. It also allows
us to move the ObjC mirrors out of Foundation in an upcoming commit.
Swift SVN r25011
Using the unknown-sized Builtin.Word types complicates producing
compile-time overflow diagnostics. If we don't know the target Word
size, we don't know if there is an overflow. But SIL optimizer does not
know the size of Word, this is the point of having the Word type in the
first place.
Also, this opens up more possibilities for optimizations.
rdar://17604532
Swift SVN r24788
Aside from tidying things up, doing this results in some significant benefits:
- Allows for global constraint ordering optimizations over a given expression, not just on a peephole basis.
- Eliminates a set of order-dependent bugs in the solver that have been dogging us for a while. (rdar://problem/19459079)
- Brings another set of tyvar-to-tyvar solving problems out of the realm of the exponential. (rdar://problem/19005271)
- Opens up the possibility of optimizing constraints during later solving phases - not just while generating them.
Swift SVN r24693
UTF16.{leadSurrogate,trailSurrogate} were converting intermediate
results to UInt16 too soon, causing a trap on U+20000 and higher.
rdar://19156359
Swift SVN r24678
Bitwise operations on Bool are redundant with other logic operations
that stdlib already provides. The only reason to have them was to avoid
branching in the short-circuiting && and ||.
rdar://19340952
Surprisingly, replacing & and | in the standard library with && and ||
brought performance improvements and no significant performance
regressions:
RecursiveOwnedParameter 1.14
SelectionSort 1.19
Swift SVN r24674
String.UTF8View and String.UTF16View may be slices that don't both start
and end on Unicode scalar boundaries, in which case conversion to a
String must fail.
Swift SVN r24669
String.UTF16Index had an init defined as internal, then redefined in the
Foundation overlay as public. This, unfortunately, did not make the
init appear to be public when Foundation was imported.
Swift SVN r24639