[fpc-pascal] Binary compatibility between Intel CPU and PowerPC CPU

Roland Turcan konf at rotursoft.sk
Tue Sep 16 20:39:03 CEST 2008


Hello all,

Thanks for all responses and I've got the answer I thought I get, but
I don't like it. :-|

Never mind. I cannot make any change on the data structure which is on
the market about 10 years, but at least I have one advantage. The
software was developed and is still used on i386 platform which means,
that the endian conversion is needed only for PowerPC computers which
are anyway old fashioned and they will vanish soon, because Apple
prefers i386 instead. The question still is, how big effort is for
PowerPC to make endian convertion.

TRoland;

<<< 16.9.2008 19:26 - Jeff Wormsley "daworm10 at comcast.net" >>>
JW> Well, the (inefficient / multiplatform - choose one) way is to not store
JW> data as binary, instead using something like XML.  Probably not an 
JW> option, but there will be a tradeoff and a penalty no matter what.  One
JW> way would be store the data in the endianness of the consistently slower
JW> platform (so as not to further slow down a system that is already 
JW> slow).  Another would be to pick the endianness of the most popular 
JW> platform for your product so that it performs as well as possible where
JW> the most users are.  Its a decision you'll have to make on your own, though.

JW> Jeff.

JW> Roland Turcan wrote:
>> Hello FPC-Pascal users discussions!
>>
>> What is the best way to keep the binary compatibility among different
>> CPU architectures.
>>
>> I need to make our own database engine compatible and other binary
>> files, that user still can use our data from i386 or PowerPC computer.
>>
>> I really don't like the idea to change the order of all numeric
>> variables on PowerPC, because it costs time of CPU.
>>
>> There must be easier way how to keep the compatibility.
>>
>> Could you give me some hints for better solution.
>>
>>   

JW> --
JW> I haven't smoked for 2 years, 4 weeks and 2 days, saving $3,427.14 and
JW> not smoking 22,847.63 cigarettes.
JW> _______________________________________________
JW> fpc-pascal maillist  -  fpc-pascal at lists.freepascal.org
JW> http://lists.freepascal.org/mailman/listinfo/fpc-pascal




-- 
Best regards, TRoland
http://www.rotursoft.sk
http://exekutor.rotursoft.sk




More information about the fpc-pascal mailing list