Openmoko Bug #1821: tee (busybox) gives bad performace: write 1 char a time
Openmoko Public Trac
bugs at docs.openmoko.org
Thu Aug 14 16:02:16 CEST 2008
#1821: tee (busybox) gives bad performace: write 1 char a time
----------------------+-----------------------------------------------------
Reporter: h.koenig | Owner: openmoko-devel
Type: defect | Status: new
Priority: normal | Milestone:
Component: unknown | Version:
Severity: normal | Keywords:
Blocking: | Blockedby:
----------------------+-----------------------------------------------------
using tee(1) to create some log file and view the output gives horrible
performace, because tee writes output one character a time (both to stdout
and to file):
to test:
echo foo | strace tee bar
gives
...
open("bar", O_WRONLY|O_CREAT|O_TRUNC|O_LARGEFILE, 0666) = 3
...
read(0, "foo\n", 1024) = 4
write(1, "f", 1f) = 1
write(3, "f", 1) = 1
write(1, "o", 1o) = 1
write(3, "o", 1) = 1
write(1, "o", 1o) = 1
write(3, "o", 1) = 1
write(1, "\n", 1
) = 1
write(3, "\n", 1) = 1
read(0, "", 1024) = 0
io_submit(0, 0, 0xfbad2098 <unfinished ... exit status 0>
Process 2475 detached
--
Ticket URL: <https://docs.openmoko.org/trac/ticket/1821>
docs.openmoko.org <http://docs.openmoko.org/trac/>
openmoko trac
More information about the buglog
mailing list