This is the mail archive of the
newlib@sourceware.org
mailing list for the newlib project.
Re: [RFC 0/4] cell offloaded stdio
- From: Kazunori Asayama <asayama at sm dot sony dot co dot jp>
- To: jschopp at austin dot ibm dot com
- Cc: newlib at sources dot redhat dot com
- Date: Mon, 04 Dec 2006 14:50:15 +0900 (LMT)
- Subject: Re: [RFC 0/4] cell offloaded stdio
- References: <4536AAE7.9000400@austin.ibm.com>
jschopp <jschopp@austin.ibm.com> wrote:
> These probably aren't ready for inclusion in the main cvs repository yet, but I would like
> some feedback on patch number 4. I'm also sending them out without changelogs and
> rebasing because others are using them and they include some bugfixes. They are very
> functional and have gone through a decent amount of testing.
I found bugs in your offloading patches. Of course, I know that these
patches are just RFCs, but anyway, I attach a patch to fix them.
Index: newlib/newlib/libc/machine/spu/putchar.c
===================================================================
--- newlib.orig/newlib/libc/machine/spu/putchar.c
+++ newlib/newlib/libc/machine/spu/putchar.c
@@ -10,7 +10,7 @@ putchar (c)
{
/* c gets overwritten before return */
- send_to_ppe(SPE_C99_SIGNALCODE, SPE_C99_GETCHAR, &c);
+ send_to_ppe(SPE_C99_SIGNALCODE, SPE_C99_PUTCHAR, &c);
return c;
}
Index: newlib/newlib/libc/machine/spu/ftell.c
===================================================================
--- newlib.orig/newlib/libc/machine/spu/ftell.c
+++ newlib/newlib/libc/machine/spu/ftell.c
@@ -12,7 +12,7 @@ _DEFUN (ftell, (fp),
myfp = translate_fp(fp);
- send_to_ppe(SPE_C99_SIGNALCODE, SPE_C99_CLEARERR, &myfp);
+ send_to_ppe(SPE_C99_SIGNALCODE, SPE_C99_FTELL, &myfp);
return *ret;
}
Index: newlib/newlib/libc/machine/spu/remove.c
===================================================================
--- newlib.orig/newlib/libc/machine/spu/remove.c
+++ newlib/newlib/libc/machine/spu/remove.c
@@ -9,7 +9,7 @@ remove (filename)
/* The return value gets written over buf
*/
- send_to_ppe(SPE_C99_SIGNALCODE, SPE_C99_GETS, &filename);
+ send_to_ppe(SPE_C99_SIGNALCODE, SPE_C99_REMOVE, &filename);
return (int)filename;
}