This is the mail archive of the
mailing list for the libstdc++ project.
Re: [Patch] Fix libstdc++/11378 (3rd take)
On Mon, Jul 14, 2003 at 01:21:55PM +0200, Paolo Carlini wrote:
> Nathan Myers wrote:
> >I don't see the above
> >as a reason to delay applying the patch. Since the problem is in
> >the existing code, and doesn't affect 11378, there's no reason not
> >to apply it and close 11378. (I suppose I should file a bug report
> >detailing this problem.)
> Thanks for bringing up the issue! I don't think it's necessary to file a
> bug report: I'm already working on the problem, which seems quite clear.
> Indeed, providing a wrapper for write seems quite simple, that for
> writev is a little more complex, but I have found around some code to
> study and adapt to our needs (just google for xwritev ;).
Note that in principle you could avoid the memmove by making filebuf's
buffer pointer handling a lot more complicated. However I don't think
it's necessary to optimize for short-write handling. A short write
should be a rare event, I think.
Does anybody know a circumstance where short writes are common enough
that performance in that case matters?