Skip to content

Commit 39f4980

Browse files
committed
---
yaml --- r: 347623 b: refs/heads/master c: b8bcb18 h: refs/heads/master i: 347621: 6bccc6d 347619: 650caa8 347615: 49937c7
1 parent ca3c837 commit 39f4980

12 files changed

+2505
-29
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
refs/heads/master: 9854088f3d5f3dc11541e43bae7058be3031c94f
2+
refs/heads/master: b8bcb18e9ff65488cdcfe393f04c77bf9fa0b47a
33
refs/heads/master-next: 203b3026584ecad859eb328b2e12490099409cd5
44
refs/tags/osx-passed: b6b74147ef8a386f532cf9357a1bde006e552c54
55
refs/tags/swift-2.2-SNAPSHOT-2015-12-01-a: 6bb18e013c2284f2b45f5f84f2df2887dc0f7dea

trunk/stdlib/public/Darwin/Accelerate/Accelerate.swift

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,3 +15,13 @@ public enum vDSP {}
1515

1616
/// An enum that acts as a namespace for Swift overlays to vForce based functions.
1717
public enum vForce {}
18+
19+
extension vDSP {
20+
public struct VectorizableFloat {
21+
public typealias Scalar = Float
22+
}
23+
24+
public struct VectorizableDouble {
25+
public typealias Scalar = Double
26+
}
27+
}

trunk/stdlib/public/Darwin/Accelerate/AccelerateBuffer.swift

Lines changed: 25 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -17,16 +17,16 @@
1717
/// provide the withUnsafeBufferPointer function.
1818
@available(iOS 9999, macOS 9999, tvOS 9999, watchOS 9999, *)
1919
public protocol AccelerateBuffer {
20-
/// The buffer's element type.
21-
associatedtype Element
22-
23-
/// The number of elements in the buffer.
24-
var count: Int { get }
25-
26-
/// Calls a closure with a pointer to the object's contiguous storage.
27-
func withUnsafeBufferPointer<R>(
28-
_ body: (UnsafeBufferPointer<Element>) throws -> R
29-
) rethrows -> R
20+
/// The buffer's element type.
21+
associatedtype Element
22+
23+
/// The number of elements in the buffer.
24+
var count: Int { get }
25+
26+
/// Calls a closure with a pointer to the object's contiguous storage.
27+
func withUnsafeBufferPointer<R>(
28+
_ body: (UnsafeBufferPointer<Element>) throws -> R
29+
) rethrows -> R
3030
}
3131

3232
/// A mutable object composed of count elements that are stored contiguously
@@ -36,29 +36,29 @@ public protocol AccelerateBuffer {
3636
/// MutableCollections, but they need not be.
3737
@available(iOS 9999, macOS 9999, tvOS 9999, watchOS 9999, *)
3838
public protocol AccelerateMutableBuffer: AccelerateBuffer {
39-
/// Calls the given closure with a pointer to the object's mutable
40-
/// contiguous storage.
41-
mutating func withUnsafeMutableBufferPointer<R>(
42-
_ body: (inout UnsafeMutableBufferPointer<Element>) throws -> R
43-
) rethrows -> R
39+
/// Calls the given closure with a pointer to the object's mutable
40+
/// contiguous storage.
41+
mutating func withUnsafeMutableBufferPointer<R>(
42+
_ body: (inout UnsafeMutableBufferPointer<Element>) throws -> R
43+
) rethrows -> R
4444
}
4545

4646
@available(iOS 9999, macOS 9999, tvOS 9999, watchOS 9999, *)
4747
public extension AccelerateBuffer where Self: Collection {
48-
func withUnsafeBufferPointer<R>(
49-
_ body: (UnsafeBufferPointer<Element>) throws -> R
50-
) rethrows -> R {
51-
return try withContiguousStorageIfAvailable(body)!
52-
}
48+
func withUnsafeBufferPointer<R>(
49+
_ body: (UnsafeBufferPointer<Element>) throws -> R
50+
) rethrows -> R {
51+
return try withContiguousStorageIfAvailable(body)!
52+
}
5353
}
5454

5555
@available(iOS 9999, macOS 9999, tvOS 9999, watchOS 9999, *)
5656
extension AccelerateMutableBuffer where Self: MutableCollection {
57-
public mutating func withUnsafeMutableBufferPointer<R>(
58-
_ body: (inout UnsafeMutableBufferPointer<Element>) throws -> R
59-
) rethrows -> R {
60-
return try withContiguousMutableStorageIfAvailable(body)!
61-
}
57+
public mutating func withUnsafeMutableBufferPointer<R>(
58+
_ body: (inout UnsafeMutableBufferPointer<Element>) throws -> R
59+
) rethrows -> R {
60+
return try withContiguousMutableStorageIfAvailable(body)!
61+
}
6262
}
6363

6464
@available(iOS 9999, macOS 9999, tvOS 9999, watchOS 9999, *)

trunk/stdlib/public/Darwin/Accelerate/CMakeLists.txt

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,19 @@ include("../../../../cmake/modules/StandaloneOverlay.cmake")
44
add_swift_target_library(swiftAccelerate ${SWIFT_SDK_OVERLAY_LIBRARY_BUILD_TYPES} IS_SDK_OVERLAY
55
Accelerate.swift
66
AccelerateBuffer.swift
7+
Quadrature.swift
78
vDSP_Arithmetic.swift
9+
vDSP_Biquad.swift
810
vDSP_ClippingLimitThreshold.swift
911
vDSP_ComplexConversion.swift
1012
vDSP_ComplexOperations.swift
1113
vDSP_Conversion.swift
1214
vDSP_Convolution.swift
15+
vDSP_DCT.swift
16+
vDSP_DFT.swift
1317
vDSP_DecibelConversion.swift
18+
vDSP_FFT.swift
19+
vDSP_FFT_DFT_Common.swift
1420
vDSP_FIR.swift
1521
vDSP_FillClearGenerate.swift
1622
vDSP_Geometry.swift
@@ -23,7 +29,6 @@ add_swift_target_library(swiftAccelerate ${SWIFT_SDK_OVERLAY_LIBRARY_BUILD_TYPES
2329
vDSP_SingleVectorOperations.swift
2430
vDSP_SlidingWindow.swift
2531
vForce_Operations.swift
26-
Quadrature.swift
2732

2833
"${SWIFT_SOURCE_DIR}/stdlib/linker-support/magic-symbols-for-install-name.c"
2934

0 commit comments

Comments
 (0)