[Mono-dev] Mono svn and ppc
andreas.faerber at web.de
Fri Dec 19 07:05:18 EST 2008
Am 19.12.2008 um 03:27 schrieb Steven Munroe:
> Paul wrote:
>> Is mono svn working yet with ppc (not ppc64)? I had to disable it for
>> fedora rawhide as there is a signing problem on PPC which looks to
>> come from a revision at 121203.
> found the bug. The update to mini-ppc.c (emit_memcpy) replaced
> macro with ppc_load_reg_update, but the definition of
> ppc_load_reg_update for PPC32 in ppc-codegen.h did not account for
> reorders parms (ppc_lwz (c, Rd, d, Ra) vs lwzu (c, Rd, Ra, d)).
That's odd. In my Git tree I was able to bootstrap ppc32 on OSX and
Fedora with my macros, no signing issues.
I had notified Mark that some macros were not committed to SVN in
their final MIT-licensed form (e.g., ppc_ld/std with ugly ds field),
but I didn't have time to look into it since then.
As for the argument order, I originally had the new macros with
instruction field order and then in the non-indented version fixed
them to reflect assembler field order, as was done for most other
macros. At least one existing but unused macro was wrong in that
aspect and fixed in my tree.
For compatibility, I think it's best to keep/use assembler argument
order for instruction macros to allow interchange with real assembler
code. The meta-macros are up to us but were intended as drop-in
replacements for the 32-bit macros.
> Net: ppc_lwz is in assembler operand order while ppc_lwzu is
> field order. The lhzu, lhau, lha, lbzu follow the lwzu form. The
> rest of
> the loads and stores follow the ppc_pwz form.
> In the long run we should make these consistent but in the short term
> the attached patch will get the PPC32 mono build working again.
> diff -urN mono-svn-20081216/mono/mono/arch/ppc/ppc-codegen.h mono-
> --- mono-svn-20081216/mono/mono/arch/ppc/ppc-codegen.h 2008-12-16
> 10:45:37.000000000 -0600
> +++ mono-svn64/mono/mono/arch/ppc/ppc-codegen.h 2008-12-18
> 19:41:31.000000000 -0600
> @@ -150,7 +150,7 @@
> #define ppc_load_func(c,D,V) ppc_load_sequence ((c), (D), (V))
> #define ppc_load_reg(c,D,d,A) ppc_lwz ((c), (D), (d), (A))
> -#define ppc_load_reg_update(c,D,d,A) ppc_lwzu ((c), (D), (d), (A))
> +#define ppc_load_reg_update(c,D,d,A) ppc_lwzu ((c), (D), (A), (d))
> #define ppc_load_reg_indexed(c,D,A,B) ppc_lwzx ((c), (D),
> (A), (B))
> #define ppc_load_reg_update_indexed(c,D,A,B) ppc_lwzux ((c), (D),
> (A), (B))
> #define ppc_load_multiple_regs(c,D,A,d) ppc_lmw ((c), (D),
> (A), (d))
> Mono-devel-list mailing list
> Mono-devel-list at lists.ximian.com
More information about the Mono-devel-list