making prcs

Discuss PocketC for Palm OS (including Desktop Edition)

Postby nickjbanks on Tue Feb 27, 2001 5:10 pm

I know you can make PRCs with the pktC desktop edition but how hard is it to go from pktC code to a stand alone programme using gcc (or something else). Am i right in thinking that a PRC made this way will run much faster?
Posts: 1
Joined: Tue Feb 27, 2001 5:03 pm
Location: United Kingdom

Postby stephane on Tue Feb 27, 2001 5:51 pm

PocketC does not create "true" PRCs, in the sense that it compiles intermediate code, that requires the runtime module to execute.

Cross compilers such as gcc and CodeWarrior, with the Palm SDK, generate a true standalone product, ie: machine code directly executable by the Palm device.

So, yes, a compiled app will run faster because there is no overhead required by a runtime to interpret the code.


Posts: 71
Joined: Fri Jan 12, 2001 3:16 am
Location: Canada

Postby jstadolnik on Tue Feb 27, 2001 5:52 pm

Currently, there is no way do this except by brute force. You'd have to create an equivalent C/C++ function for every PocketC function you use.

Since C doesn't have a string data type and it doesn't handle automatic type conversions like pocketC, you'd have to fake that out somehow.

If someone were ambitious enough they could write a C library to replace every pocketC function. This would make translation significantly easier.

The hardest of these functions to write would be the event related ones (they could also be expanded to support native palm forms).

And yes, a program compiled with gcc or codewarrior would run signigicantly faster than it's pocketC equivalent.

Posts: 1741
Joined: Wed Dec 06, 2000 3:34 am
Location: USA

Return to PocketC for Palm OS

Who is online

Users browsing this forum: No registered users and 2 guests