[futurebasic] Re: Re: [FB] FB^3 FAQs [was: Convert 68K assem to PPC assem]

Message: < previous - next > : Reply : Subscribe : Cleanse
Home   : September 1999 : Group Archive : Group : All Groups

From: BMichael@...
Date: Sat, 18 Sep 1999 02:18:59 EDT
>Yes my target is FB^3 but I still have to overcome the conversion of 68K to
>PPC assembler. Some of the filter I mentioned is coded in native inline 68K
>assembler.  I would like to use a conditional compile like the example
>shown below (copied from Runtime.INCL in FB^3). OK, I realize that 100%
>native code is NOT necessary and the 68K code will run in mixed mode via
>the emulator. My goal is to have 100% PPC code or 100% 68K code.

It took a while for me to overcome this same mindset... I was convinced 
that because parts of my app were in 68K assembler for speed, that they 
needed to be in PPC assembler for speed. Then Andy proved that rewriting 
the code in FB^3 "straight", no assembler, and using the 68K assembler 
code for the 68K version and the FB code for the PPC version (simple with 
a conditional compile), the PPC version was _still_ faster than the 68K 
version. And it's _much_ easier to convert from 68K to FB than from 68K 
to PPC, for us "normal" humans!

Yes, it's a good idea to avoid mixed-mode calls (especially since they're 
real "iffy" right now, and _gone_ with OS/X anyway!); but there's no 
longer any real _need_ for "raw" assembler, at least not on the PPC side. 
Only in very particular circumstances can I imagine having to use PPC 
assembler. FB^3-generated PPC code is "wicked fast"...

>compile long if cpu68k
>` move.l ^gFBGLocalsPtr&,A6
>compile end if
>
>compile long if cpuPPC
>` lwz  r13,^gFBGLocalsPtr&
>compile end if

This is one of those cases; this is not for speed, but because the 
register structure of the two is so different.

Which part of PowerPack are you working on? The 3D-Text stuff is being 
discussed over on the beta list right now - Andy's already rewritten one 
part, and somebody else has done quite a bit. I haven't been following it 
much, but email me privately and I'll at least "coordinate" the efforts...

>Are these FAQs on futurebasic.org?

Not yet....

Bill