[Cbe-oss-dev] [PATCH] libea ppe side support

Kazunori Asayama asayama at sm.sony.co.jp
Wed Jul 4 17:27:06 EST 2007


Joel Schopp <jschopp at austin.ibm.com> wrote:
> > I have a question about the SPE side. Is it planned to share
> > __send_to_ppe, which is the common and public PPE assisted-call
> > support function in newlib, between newlib and libea ? If so, I
> > suppose that we need to change the external interface of __send_to_ppe
> > because a handle 64 bit value can't be returned via the current
> > interface.
> 
> It is planned to share __send_to_ppe().  In fact the current implementation of libea 
> actually just builds it into the machine specific part of newlib and ships it as part 
> of libc.a.  The -mea32 vs -mea64 issue is taken care of in the ea.h header that does 
> conditional substitution.  For example a call to malloc_ea() compiled with -mea64 
> becomes __malloc_ea64() and when compiled with -mea32 becomes __malloc_ea32(). 
> Newlib libc.a then has __malloc_ea64() and __malloc_ea32() objects to link against.

Does it mean that new flags -mea32 and -mea64 will be added to spu-gcc ?

> 
> The current interface to __send_to_ppe returns an array of 4 32 bit values over the 
> passed in arguments, the first argument is also returned as an int from the function, 
> and the 4th argument is the errno which is copied to the local errno.  So functions 
> needing to fetch 64 bit values just need to look at slots 0 & 1 as a single 64 bit value.

OK, I understand. The current your local version of __send_to_ppe has
different interface from the upstream newlib's one, right ?

--
(ASAYAMA Kazunori
  (asayama at sm.sony.co.jp))
t



More information about the cbe-oss-dev mailing list