[Gambas-devel] porting Gambas to pcc

Benoit Minisini gambas at ...1...
Thu Apr 19 08:12:44 CEST 2007


On jeudi 19 avril 2007, chintan rao wrote:
> Hi,
> Also I would like to know how much of the porting has laready been done
> ( I mean is there any part of the interpreter / compiler code which is
> written for power pc architecture)
> and what help will i get :)
>
> On 4/18/07, chintan rao <chintanraoh at ...176...> wrote:
> > hi all,
> > We ,at our college, have a power processor based server which is
> > supposed to be used for porting applications to ppc architecture.
> > I would like to know what  would this take to do and how feasible it is.
> > I have got over  2 months of holidays to do this if is feasible.
> >
> > Chintan
>
Hi,

There are two problems with PowerPC:
1) Endianness-neutral.
2) 64-bits.

The 1) is partially implemented, but is buggy. I mean it crashes, but I could 
never debugged as I don't have a big-endian system.

When generating a compiled file, the compiler writes the endianness of the CPU 
at the beginning of the file (gbc_output.c:289). 

When the interpreter reads this file, it has to swap things where things need 
to be swapped. This is done in the gbx_class_load.c file, from the line 356. 
This swapping process seems to need debugging.

The 2) is a far more difficult work, as it needs to clean and rewrite a lot of 
things in the source code of the compiler and interpreter. Especially the 
interpreter that relies on too many places on 32 bits integers and pointers.

This almost needs a new interpreter, so I don't want to do that before 2.0.

Tell me what you can do, or want to do exactly.

Thanks for your collaboration proposal!

Regards,

-- 
Benoit Minisini




More information about the Devel mailing list