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
dispatch_once calls on every load from it
Performance improvements, as reported by the perf testing buildbot:
Histogram -18.81%
TwoSum -17.42%
RGBHistogram -9.65%
Regressions:
InsertionSort 5.59%
ArrayOfRef 3.99%
SwiftStructuresInsertionSort 5.29%
PrimeNum 6.09%
These regressions are bogus. The tests that "regressed" don't do any
hashing at all.
Swift SVN r23995
Pinning an object prevents it from being deallocated,
just like retaining it, but only one client can own the
pin at once. Sensible "sharing" of the pin can occur
if attempts are perfectly nested. It is efficient to
simultaneously query the pin state of an object in
conjunction with its strong reference count.
This combination of traits makes pinning suitable for
use in tracking whether a data structure backed by
an object is undergoing a non-structural modification:
- A structural change would require unique ownership
of the object, but two non-structural changes (to
different parts of the object) can occur at once
without harm. So a non-structural change can check
for either uniqueness or a pin and then, if necessary,
assert the pin for the duration of the change.
Meanwhile, this act of asserting the pin prevents
simultaneous structural changes.
- A very simple code-generation discipline leads to
changes being perfectly nested as long as they're
all performed by a single thread (or synchronously).
Asynchrony can introduce imperfect nesting, but it's
easy to write that off as a race condition and hence
undefined behavior.
See Accessors.rst for more on both of these points.
Swift SVN r23761
This is currently unimplemented as of this macro being 20141011,
when it is implemented in libstdc++ the check should be changed
to a < the version that implemented it.
Swift SVN r23368
Renames swift_class_getInstanceSize to
swift_class_getInstancePositiveExtentSize to reflect that it is
the size of the object after the instance address point.
Swift SVN r23333
stdint.h and stddef.h are shipped with CLang, but they not included in
Clang's module.map, which causes Clang to import libc versions instead
(and Clang's stdint.h is dispatching to libc). This was causing
hard-to-debug transient failures during incremental rebuilds, like this:
error: module file was created by an older version of the compiler: .../Darwin.swiftmodule
Swift SVN r23230
Generated code on x86_64 for swift_retain and swift_release and
swift_allocObject are unchanged. arm64 is improved by using weaker
memory barriers, fixing rdar://17423624.
Swift SVN r22887
It was doing an unsafeBitCast and possibly not managing lifetimes;
replace it with more-typesafe and memory-safe calls where possible.
Swift SVN r22779
A revamped version of HeapBuffer that doesn't allow null buffer
references. Something like this is needed for killing the null array
state.
Swift SVN r22683
Cleaning this output sometimes fails to delete the folder, as does CMake's
heavy-handed sop to Xcode's suboptimal dependency analysis ("delete any
dependents"). Since the contents of the folder are already listed as outputs,
we should be fine.
Swift SVN r22606
Make unique reference checking available to users, making ManagedBuffer
a complete facility for building COW value types. Also rationalize the
way we name and organize the runtime primitives we ultimately call.
Swift SVN r22594
Since ObjC functions take their arguments at +0, we don't need to erase
"object-ness" in order to avoid disturbing reference counts. This
interacts much better with lifetime optimizations, since the caller must
ensure the argument isn't released until these functions return.
Swift SVN r22580
NFC, and no significant performance change expected. This is part one
of a move to eliminate nil checks from the array implementation.
Swift SVN r22526
NFC, and no significant performance change expected. This is part one
of a move to eliminate nil checks from the array implementation.
Swift SVN r22495
This patch adds a compiler entry point to the standard library that checks
whether the running OS version is greater than or equal to a given version
triple. The idea is that #os(...) will get SILGen'd into a call to this
function.
The standard library function calls a runtime function to actually get the OS
version. This runtime function uses -[NSProcessInfo operatingSystemVersion] when
possible, otherwise it loads the SystemVersion plist. When running under the
simulator, we use an environmental variable set by the simulator to look up the
version for the simulated OS and not the host OS.
At the moment, there is no caching for version info. I will add this in a later
patch.
Swift SVN r22303
For reasons not entirely clear yet, this can cause problems in the
compiler when some modules bring in the same names via the Darwin
module (see <rdar://problem/18184795>). Use SwiftShims instead.
Swift SVN r21646