File tree Expand file tree Collapse file tree 1 file changed +0
-41
lines changed Expand file tree Collapse file tree 1 file changed +0
-41
lines changed Original file line number Diff line number Diff line change @@ -137,45 +137,4 @@ public class ParserTests: ParserTestCase {
137
137
checkDiagnostics: false
138
138
)
139
139
}
140
-
141
- func testSelfParsePerformance( ) throws {
142
- try XCTSkipUnless ( ProcessInfo . processInfo. environment [ " ENABLE_SELF_PARSE_PERFORMANCE " ] == " 1 " )
143
-
144
- let sourceDir = packageDir. appendingPathComponent ( " Sources " )
145
- let files = try FileManager . default
146
- . enumerator ( at: sourceDir, includingPropertiesForKeys: nil ) !
147
- . compactMap ( { $0 as? URL } )
148
- . filter { $0. pathExtension == " swift " }
149
- . map { try Data ( contentsOf: $0) }
150
-
151
- measure {
152
- for _ in 0 ..< 10 {
153
- for file in files {
154
- file. withUnsafeBytes { buf in
155
- _ = Parser . parse ( source: buf. bindMemory ( to: UInt8 . self) )
156
- }
157
- }
158
- }
159
- }
160
- }
161
-
162
- func testConcurrentSelfParsePerformance( ) throws {
163
- try XCTSkipUnless ( ProcessInfo . processInfo. environment [ " ENABLE_SELF_PARSE_PERFORMANCE " ] == " 1 " )
164
-
165
- let sourceDir = packageDir. appendingPathComponent ( " Sources " )
166
- let files = try FileManager . default
167
- . enumerator ( at: sourceDir, includingPropertiesForKeys: nil ) !
168
- . compactMap ( { $0 as? URL } )
169
- . filter { $0. pathExtension == " swift " }
170
- . map { try Data ( contentsOf: $0) }
171
-
172
- measure {
173
- DispatchQueue . concurrentPerform ( iterations: files. count * 50 ) { i in
174
- let file = files [ i % files. count]
175
- file. withUnsafeBytes { buf in
176
- _ = Parser . parse ( source: buf. bindMemory ( to: UInt8 . self) )
177
- }
178
- }
179
- }
180
- }
181
140
}
You can’t perform that action at this time.
0 commit comments