| Summary: | [PATCH] Increase speed of split(1) | ||||||
|---|---|---|---|---|---|---|---|
| Product: | Base System | Reporter: | George Reid <greid> | ||||
| Component: | bin | Assignee: | freebsd-bugs (Nobody) <bugs> | ||||
| Status: | Closed FIXED | ||||||
| Severity: | Affects Only Me | ||||||
| Priority: | Normal | ||||||
| Version: | 5.0-CURRENT | ||||||
| Hardware: | Any | ||||||
| OS: | Any | ||||||
| Attachments: |
|
||||||
Responsible Changed From-To: freebsd-bugs->greid Over to originator. State Changed From-To: open->suspended Did this patch ever get committed? Responsible Changed From-To: greid->linimon Take over from inactive committer to track feedback. Responsible Changed From-To: linimon->freebsd-bugs Turn this back over to the pool. State Changed From-To: suspended->closed Mail to submitter bounces. |
The speed of split(1) can be increased by using dynamically-allocated buffers. The following results are from a large file created with dd if=/dev/zero of=bigfile bs=1024k count=300 $ /usr/bin/time split -b 1024k bigfile 90.19 real 0.02 user 22.42 sys $ /usr/bin/time ./mysplit -b 1024k bigfile 81.81 real 0.04 user 25.60 sys This could represent problems on systems with low memory (perhaps further modification is needed), but given that the average amount of memory being distributed with PCs nowadays, this might be useful.