Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

P-Code vs. Native?

Status
Not open for further replies.

ducksoup

Programmer
Aug 17, 2001
35
US
What does the compile to p-code option do, in the project preferences? You don't see with your eyes, you perceive with your mind.
 
p-code stands for pseudo-code i.e. code that the CPU cannot execute directly. BASIC has always been an interpreted language. Its statements were not translated directly into machine language, instead they were translated into a more compact form which in turn was re-translated into machine language immediately prior to execution. Therefore, p-code will compile faster, but execution will be slower. (though the process of ranslating p-code into executable code is highly efficient)

The main benefit of p-code is that it is compact and not too much slower than executable machine code. But you do pay this (however small) penalty at each execution of your program. _________________________________
In theory, there is no difference between theory and practice. In practice, there is. [attributed to Yogi Berra]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top