Commit ba4eae0
Reduce allocations for CreateDirectory (#61777)
* introduce an overload that accepts ROS<char> instead of a string
* remove dead code
* avoid string allocations
* remove List<int> allocation
* Apply suggestions from code review
Co-authored-by: Stephen Toub <stoub@microsoft.com>1 parent b4d16b7 commit ba4eae0
File tree
4 files changed
+24
-39
lines changed- src/libraries
- Common/src/Interop/Unix/System.Native
- System.IO.Pipes/src
- System/IO/Pipes
- System.Private.CoreLib/src/System/IO
4 files changed
+24
-39
lines changedLines changed: 10 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3 | 3 | | |
4 | 4 | | |
5 | 5 | | |
| 6 | + | |
6 | 7 | | |
7 | 8 | | |
8 | 9 | | |
9 | 10 | | |
10 | 11 | | |
11 | | - | |
12 | | - | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
13 | 21 | | |
14 | 22 | | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
137 | 137 | | |
138 | 138 | | |
139 | 139 | | |
140 | | - | |
141 | | - | |
142 | 140 | | |
143 | 141 | | |
144 | 142 | | |
| |||
166 | 164 | | |
167 | 165 | | |
168 | 166 | | |
169 | | - | |
| 167 | + | |
170 | 168 | | |
171 | 169 | | |
172 | 170 | | |
| |||
Lines changed: 0 additions & 17 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
434 | 434 | | |
435 | 435 | | |
436 | 436 | | |
437 | | - | |
438 | | - | |
439 | | - | |
440 | | - | |
441 | | - | |
442 | | - | |
443 | | - | |
444 | | - | |
445 | | - | |
446 | | - | |
447 | | - | |
448 | | - | |
449 | | - | |
450 | | - | |
451 | | - | |
452 | | - | |
453 | | - | |
454 | 437 | | |
455 | 438 | | |
456 | 439 | | |
| |||
Lines changed: 13 additions & 17 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
298 | 298 | | |
299 | 299 | | |
300 | 300 | | |
301 | | - | |
| 301 | + | |
302 | 302 | | |
303 | | - | |
304 | 303 | | |
305 | 304 | | |
306 | 305 | | |
| |||
309 | 308 | | |
310 | 309 | | |
311 | 310 | | |
312 | | - | |
| 311 | + | |
313 | 312 | | |
314 | 313 | | |
315 | 314 | | |
316 | | - | |
317 | | - | |
318 | | - | |
| 315 | + | |
| 316 | + | |
319 | 317 | | |
320 | 318 | | |
321 | | - | |
322 | 319 | | |
323 | 320 | | |
324 | | - | |
| 321 | + | |
325 | 322 | | |
| 323 | + | |
326 | 324 | | |
327 | 325 | | |
328 | 326 | | |
| |||
332 | 330 | | |
333 | 331 | | |
334 | 332 | | |
335 | | - | |
336 | | - | |
| 333 | + | |
337 | 334 | | |
338 | 335 | | |
339 | 336 | | |
340 | | - | |
341 | | - | |
| 337 | + | |
342 | 338 | | |
343 | 339 | | |
344 | 340 | | |
| |||
348 | 344 | | |
349 | 345 | | |
350 | 346 | | |
351 | | - | |
| 347 | + | |
352 | 348 | | |
353 | 349 | | |
354 | 350 | | |
| |||
358 | 354 | | |
359 | 355 | | |
360 | 356 | | |
361 | | - | |
| 357 | + | |
362 | 358 | | |
363 | 359 | | |
364 | 360 | | |
365 | 361 | | |
366 | 362 | | |
367 | | - | |
| 363 | + | |
368 | 364 | | |
369 | | - | |
| 365 | + | |
370 | 366 | | |
371 | 367 | | |
372 | 368 | | |
| |||
386 | 382 | | |
387 | 383 | | |
388 | 384 | | |
389 | | - | |
| 385 | + | |
390 | 386 | | |
391 | 387 | | |
392 | 388 | | |
| |||
0 commit comments