Re: [Gc] Please update Renesas SH support

Ivan Maidanski ivmai at mail.ru
Fri Jan 22 00:08:43 PST 2010


Hi!
Nobuhiro Iwamatsu <iwamatsu at nigauri.org> wrote:
> Hi,
> 
> libatomic-ops supports AO_test_and_set_full only on Renesas SH (sh4).
> However, this does not support an AO_compare_XXX function.
> sh4 has to use AO_compare_XXX_emulation function for compatibility
> with other SH cpu.
> Please support emulation of AO_compare_XXX_emulation function.
> 
> I made patch. Could you apply this patch?

No. It's wrong.
By atomic_ops design, AO_REQUIRE_CAS is defined by the client when needed (e.g., see that in include/private/gc_priv.h).

> 
> Best regards,
>  Nobuhiro
> 
> -- 
> Nobuhiro Iwamatsu
>    iwamatsu at {nigauri.org / debian.org}
>    GPG ID: 40AD1FA6
> 
> --- a/src/atomic_ops.hg	2010-01-21 04:45:04.000000000 +0000
> +++ b/src/atomic_ops.h	2010-01-21 04:45:47.000000000 +0000
> @@ -243,6 +243,7 @@
>  # endif /* __mips__ */
>  # if defined(__sh__) || defined(SH4)
>  #   include "atomic_ops/sysdeps/gcc/sh.h"
> +#   define AO_REQUIRE_CAS
>  #   define AO_CAN_EMUL_CAS
>  # endif /* __sh__ */
>  #endif /* __GNUC__ && !AO_USE_PTHREAD_DEFS */

Bye.


More information about the Gc mailing list