[patch] Fix MIPS pipe, brk

Atsushi Nemoto anemo at mba.ocn.ne.jp
Thu Jan 5 00:22:05 UTC 2006


>>>>> On Wed, 4 Jan 2006 17:33:55 +0000 (UTC), "Joseph S. Myers" <joseph at codesourcery.com> said:
joseph> It turns out pipe.S was also buggy (crashing the program in
joseph> the error case).  This patch fixes pipe.S and removes pipe.c.
joseph> The previously sent brk.c patch should still be applied as
joseph> well; a corresponding brk.c change is now in glibc.

Hi.  In MIPS pipe function, there is no need to save/restore a0 on
stack.  AFAIK kernel preserves a0 value on syscall entry/exit.  If a0
was not preserved, it would be a bug in the kernel.

And if a0 was preserved, there is no need to increment/decrement sp.
It would make pipe.S simpler (as glibc's pipe implementation).

---
Atsushi Nemoto



More information about the uClibc mailing list